hejone.php
来自「实现flash的饼图投票」· PHP 代码 · 共 47 行
PHP
47 行
<?PHP
/*
[Hejone] Hejone.php
Program Author: hejone(hejone@sina.com)
Program Version:1.0_n
Copyright:hejone http://www.ha365.com
Last Modified:09/16/2004
*/
include("mysql.php");
class Hejone extends mysql {
function Hejone(){
$this->methodTable = array(
"getQuestion" => array(
"description" => "return question",
"access" => "remote",// available values are private, public, remote
"arguments" => array("arg1")
),
"getOptions" => array(
"description" => "return options",
"access" => "remote",
"arguments" => array("arg1")
),
"submitPoll" => array(
"description" => "submit ......",
"access" => "remote",
"arguments" => array("id")
)
);
$this->connect_sql();
}
//
function getQuestion(){
return mysql_query("SELECT * FROM question");
}
//
function getOptions(){
return mysql_query("SELECT * FROM options");
}
//
function submitPoll($id){
return mysql_query("UPDATE options SET num = num+1 WHERE id = '$id'");
}
}
?>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?