📄 stats.php
字号:
<?
################################################################################
# phpQuestionnaire Version 2.2 #
# Copyright 2003-2005 chumpsoft, inc. March 28, 2005 #
################################################################################
# SCRiPTMAFiA 2005 - THE DiRTY HANDS ON YOUR SCRiPTS #
################################################################################
#-->> Including Files
require("inc/init.php");
require("inc/mysql.php");
require("inc/functions.php");
require("inc/pfunctions.php");
require("inc/sfunctions.php");
#-->> GET and POST Variables
$varnames = array("st", "vw", "sid", "cq", "qcount", "fa");
SetVars($varnames);
$mqsurvey = mysql_query("select * from phpQSurvey where SID = \"".ProtectMySQL($sid)."\"");
if (!($masurvey = mysql_fetch_array($mqsurvey))) {
header("Location: error.php");
exit();
}
#-->> Logging In (if survey results are not public)
$admin = IsAdmin() ? true : false;
if (!$admin) {
if (!$masurvey["SurveyResults"]) {
header("Location: admin/index.php");
exit();
}
elseif ($masurvey["Active"] == 'n') {
header("Location: fillsurvey.php?sid=".ProtectHTML($sid));
exit();
}
}
elseif (!$fa) { $admin = false; }
#-->> Set Language
if ($admin) { SetLanguage('', 'ADMIN'); }
else { SetLanguage($masurvey['Language']); }
#-->> Checking $st
if (!$st) { $st = 'a'; }
if ($st != 'v' && $st != 'u' && $st != 'a') {
header("Location: choose.php");
exit();
}
#-->> Results
$vw = ($vw=="a" || $vw=="p" || substr($vw,0,1) == "q") ? $vw : "n";
$contents = CreateStats($masurvey, $st, $vw, $admin);
#-->> Output Page
CreatePage("stats", $masurvey, $contents, $admin, "jsstats.php");
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -