Ejemplo n.º 1
0
<?php

require_once "praveenlib.php";
require_once "applib.php";
$keys = array("eventId");
$respjson = array("status" => "unprocessed", "errorCode" => 1);
if (checkPOST($keys)) {
    $conn = connectSQL();
    if ($conn) {
        $eventId = safeString($conn, $_POST['eventId']);
        $sql = "delete from events  where eventId={$eventId}";
        if ($result = $conn->query($sql)) {
            $sql = "select userToken from users where id in (select userId from eventregistration where eventId={$eventId})";
            if ($result = $conn->query($sql)) {
                $ids = array();
                while ($row = $result->fetch_array()) {
                    $ids[] = $row[0];
                }
                $retJSON = sendPushNotification($ids, "Event Removed", $eventName . " is Removed");
                $respjson["pushReturn"] = $retJSON;
                $respjson["status"] = "Success";
                $respjson["errorCode"] = 0;
            } else {
                $respjson["status"] = "SQL error";
                $respjson["SqlError"] = $conn->error;
                $respjson["errorCode"] = 4;
            }
        } else {
            $respjson["status"] = "SQL error";
            $respjson["SqlError"] = $conn->error;
            $respjson['sql'] = $sql;
Ejemplo n.º 2
0
    }
    // Sanitize email
    $email = sanitize::email($args['email']);
    // Install Bludit
    install($args['password'], $email, $args['timezone']);
    return true;
}
// ============================================================================
// MAIN
// ============================================================================
$error = '';
if (alreadyInstalled()) {
    exit('Bludit already installed');
}
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
    $error = checkPOST($_POST);
    if ($error === true) {
        if (!headers_sent()) {
            header("Location:" . HTML_PATH_ROOT, TRUE, 302);
            exit;
        }
        exit('<meta http-equiv="refresh" content="0; url="' . HTML_PATH_ROOT . '">');
    }
}
?>
<!DOCTYPE HTML>
<html class="uk-height-1-1 uk-notouch">
<head>
	<base href="bl-kernel/admin/themes/default/">
	<meta charset="<?php 
echo CHARSET;
Ejemplo n.º 3
0
        $Ventas = checkPOST("Ventas");
        $Finanzas = checkPOST("Finanzas");
        $Cobros = checkPOST("Cobros");
        $Pagos = checkPOST("Pagos");
        $CajaGeneral = checkPOST("CajaGeneral");
        $CajaTPV = checkPOST("CajaTPV");
        $Presupuestos = checkPOST("Presupuestos");
        $ComprobantesCompra = checkPOST("ComprobantesCompra");
        $ComprobantesVenta = checkPOST("ComprobantesVenta");
        $Promociones = checkPOST("Promociones");
        $Kardex = checkPOST("Kardex");
        $Ajustes = checkPOST("Ajustes");
        $VerAjuste = checkPOST("VerAjustes");
        $Almacen = checkPOST("Almacen");
        $PedidosVenta = checkPOST("PedidosVenta");
        $Sat = checkPOST("Sat");
        $Suscripcion = checkPOST("Suscripcion");
        $Servicios = checkPOST("Servicios");
        ModificarPerfil($id, $nombre, $Admin, $Informes, $InformeLocal, $Productos, $Compras, $Stocks, $Clientes, $TPV, $Proveedores, $VerStocks, $Precios, $Ventas, $Finanzas, $Cobros, $Pagos, $CajaGeneral, $CajaTPV, $Presupuestos, $ComprobantesCompra, $ComprobantesVenta, $Promociones, $Kardex, $Ajustes, $VerAjuste, $Almacen, $B2B, $PedidosVenta, $Sat, $Suscripcion, $Servicios);
        Separador();
        PaginaBasica();
        break;
    case "editar":
        $id = CleanID($_GET["id"]);
        MostrarPerfilParaEdicion($id);
        break;
    default:
        PaginaBasica();
        break;
}
PageEnd();
Ejemplo n.º 4
0
<?php

require_once "praveenlib.php";
require_once "applib.php";
function cmp($a, $b)
{
    if ($a[2] == $b[2]) {
        return 0;
    }
    return $a[2] < $b[2] ? -1 : 1;
}
$respjson = array("status" => "unprocessed", "errorCode" => 1);
$postKeys = array("lat", "lon");
if (checkPOST($postKeys)) {
    $conn = connectSQL();
    if ($conn) {
        $sql = "select eventName,eventId,latitude,longitude from events WHERE  eventDate>NOW()";
        if ($result = $conn->query($sql)) {
            $respjson["list"] = array();
            while ($row = $result->fetch_array()) {
                $entry = array($row['eventId'], $row['eventName']);
                $entry[] = distance($_POST['lat'], $_POST['lon'], $row['latitude'], $row['longitude']);
                $respjson["list"][] = $entry;
                usort($respjson["list"], "cmp");
            }
            $respjson["status"] = "Success";
            $respjson["errorCode"] = 0;
        } else {
            $respjson["status"] = "SQL error";
            $respjson["SqlError"] = $conn->error;
            $respjson["errorCode"] = 4;
Ejemplo n.º 5
0
<head>
	<meta charset="UTF-8">
	<title>Scrapp Test</title>
	<link rel="stylesheet" href="./css/style.css">
</head>
<body>
	<div class="box">
		<ul class="webs">
			<li><a href="./index.php?url=http://wwwhatsnew.com/&mainclass=article[class=post]">Wwwhatsnew</a></li>
			<li><a href="./index.php?url=http://loogic.com/&mainclass=div[class=post]">Loogic</a></li>
			<li><a href="./index.php?url=http://www.genbeta.com/&mainclass=div[class=article-classic]">Genbeta</a></li>
			<li><a href="./index.php?url=http://www.genbetadev.com/&mainclass=div[class=article-classic]">Genbeta DEV</a></li>
			<li><a href="./index.php?url=http://www.xataka.com/&mainclass=div[class=article-classic]">Xataka</a></li>
			<li><a href="./index.php?url=http://www.vidaextra.com/&mainclass=div[class=article-classic]">VidaExtra</a></li>
		</ul>
		<?php 
    if ($_GET['url'] && $_GET['mainclass']) {
        $url = $_GET['url'];
        $mainclass = $_GET['mainclass'];
        checkPOST($url, $mainclass);
    }
    ?>
	</div>
	<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
	<script>window.jQuery || document.write('<script src="./public/assets/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>

	<script src="js/main.js"></script>
</body>
</html>
<?php 
}