本文整理汇总了PHP中DbConnect::queryRest方法的典型用法代码示例。如果您正苦于以下问题:PHP DbConnect::queryRest方法的具体用法?PHP DbConnect::queryRest怎么用?PHP DbConnect::queryRest使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DbConnect
的用法示例。
在下文中一共展示了DbConnect::queryRest方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: alert
echo "<p> <script language=\"javascript\"> alert(\"对不起,现在不在订餐时间,请在11:50-16:30或17:30到第二天10:50间订餐\"); </script> </p>";
exit;
}
if ($time == 4 and !isset($_GET['a'])) {
echo "<p> <script language=\"javascript\"> alert(\"对不起,现在不在订餐时间,请在11:50-16:30或17:30到第二天10:50间订餐\"); </script> </p>";
exit;
}
$type = 0;
if (!isset($_GET['type'])) {
$type = 1;
} else {
$type = $_GET['type'];
}
if ($type == 1) {
echo "<div id='main'>";
$result = DbConnect::queryRest();
while ($row = mysql_fetch_array($result)) {
if (isset($_GET['rest']) && $_GET['rest'] == $row['restid']) {
echo "<div class=\"presssubmenu\" onclick=\" location.href='/order.php?rest=" . $row['restid'] . "';\">";
echo $row['name'] . "</div>";
} else {
echo "<div class=\"submenu\" onclick=\" location.href='/order.php?rest=" . $row['restid'] . "';\">";
echo $row['name'] . "</div>";
}
}
echo "<div id='main'>";
}
if ($type == 2) {
echo "<div id='main'>";
$result = DbConnect::queryType();
while ($row = mysql_fetch_array($result)) {
示例2: alert
echo "<p> <script language=\"javascript\"> alert(\"对不起~我们的订餐时间已经截止,勤劳的运送员已经在采购~12点左右,美食就能出现在宿舍门口啦。没有订餐的同学不要着急下午的订餐时间将在11点50后开放\"); </script> </p>";
exit;
}
if (($time == 4 and !isset($_GET['a'])) && !DbConnect::queryAdmin($username)) {
echo "<p> <script language=\"javascript\"> alert(\"对不起~我们的订餐时间已经截止,勤劳的运送员已经在采购~5点半左右,美食就能出现在宿舍门口啦。没有订餐的同学不要着急下一次订餐时间将在17:30后开放\"); </script> </p>";
exit;
}
$type = 0;
if (!isset($_GET['type'])) {
$type = 1;
} else {
$type = $_GET['type'];
}
if ($type == 1) {
echo "<div id='main'>";
$result = DbConnect::queryRest($status);
while ($row = mysql_fetch_array($result)) {
if (isset($_GET['rest']) && $_GET['rest'] == $row['restid']) {
echo "<div class=\"presssubmenu\" onclick=\" location.href='/order.php?rest=" . $row['restid'] . "';\">";
echo $row['name'] . "</div>";
} else {
echo "<div class=\"submenu\" onclick=\" location.href='/order.php?rest=" . $row['restid'] . "';\">";
echo $row['name'] . "</div>";
}
}
echo "<div id='main'>";
}
if ($type == 2) {
echo "<div id='main'>";
$result = DbConnect::queryType();
while ($row = mysql_fetch_array($result)) {