コード例 #1
0
ファイル: plot.php プロジェクト: BackupTheBerlios/samouk-svn
}
// cleanup
if (isset($HTTP_GET_VARS["lastquery"])) {
    $HTTP_GET_VARS["lastquery"] = clean_param($HTTP_GET_VARS["lastquery"], PARAM_HOST);
}
// check if it is the user's ip, or another host
if (!isset($HTTP_GET_VARS["address"]) || $HTTP_GET_VARS["address"] == "") {
    $address = $HTTP_SERVER_VARS['REMOTE_ADDR'];
    $local = 1;
} else {
    $HTTP_GET_VARS["address"] = clean_param($HTTP_GET_VARS["address"], PARAM_HOST);
    $address = $HTTP_GET_VARS["address"];
    $local = 0;
}
// this is the most important function, gets lat/lon and description of location
$values = getstuff($address, $local) or die("Error in plot.inc");
if (isset($logging) && is_writable("plotlog.txt")) {
    $log = @fopen("plotlog.txt", "a") or print "";
    @fputs($log, $HTTP_SERVER_VARS["REMOTE_ADDR"] . "\t" . date("F j, Y, g:i a") . "\t{$address}\t{$values['address']}\t{$values['lat']}\t{$values['lon']}\n") or print "";
    @fclose($log);
}
if (isset($HTTP_COOKIE_VARS["atlasprefs"]) && validcookie($HTTP_COOKIE_VARS["atlasprefs"])) {
    list(, , , $imagething) = split(":", $HTTP_COOKIE_VARS["atlasprefs"]);
    $imagething = clean_param($imagething, PARAM_FILE);
    $earthimage = isvalidimage($imagething, $earthimages, $defaultimage);
} else {
    $earthimage = $earthimages[$defaultimage];
}
if (strstr($earthimage, ":")) {
    list($earthimage, , , ) = split(":", $earthimage);
}
コード例 #2
0
ファイル: getstuff3.php プロジェクト: gaoerjun/Web
        $stuff_mass = $row["mass"];
        //弥撒
        $stuff_med = $row["med"];
        //日祷
        $stuff_comp = $row["comp"];
        //夜祷
        $stuff_let = $row["let"];
        //诵读
        $stuff_lod = $row["lod"];
        //晨祷
        $stuff_thought = $row["thought"];
        //反省
        $stuff_ordo = $row["ordo"];
        //礼仪
        $stuff_ves = $row["ves"];
        //晚祷
        $stuff_saint = $row["saint"];
        //圣人传记
        gotoend();
    } else {
        if ($row['lastupdate'] == date('Y-m-d')) {
            $errorcode = 2;
            error();
        } else {
            getstuff();
        }
    }
} else {
    getstuff();
}
//	echo json_encode($retArray,JSON_UNESCAPED_UNICODE|JSON_UNESCAPED_SLASHES);