Action. php file? Phprequire (config. php); $ action $ arr_request [action]; $ key_liuyan $ arr_request [key_liuyan]; if (! Isset ($ PHP_AUTH_USER) {Header (WWW-Authenticate: Basicrealm management message); Header (HTTP1.0401Unauthorized); echo requires authorization, you do not have the action. php file
Require ('config. php ');
$ Action = $ arr_request ['action'];
$ Key_liuyan = $ arr_request ['key _ liuyan '];
If (! Isset ($ PHP_AUTH_USER ))
{
Header ('www-Authenticate: Basic realm = "manage messages "');
Header ('http/1.0 401 unauthorized ');
Echo 'requires authorization. you do not have this permission!
';
Echo 'click refresh to retry.
';
Exit;
}
Else
{
If (strlen ($ PHP_AUTH_USER )! = 0)
{
If ($ action = "delete ")
Echo "Sorry, you have no permission to delete the message !!!
";
Else if ($ action = "huifu ")
Echo "Sorry, you cannot recover it now. now only the moderator has this permission !!!
";
Else
Echo "Sorry, you have no permission to manage message books !!! ";
Exit;
}
$ Pass = $ PHP_AUTH_PW;
// Echo $ pass;
$ Result = 0;
While ($ pass! = 0)
{
$ Result = $ result $ pass;
$ Pass = ($ pass-$ pass)/10;
// Echo $ result;
// Echo"
";
}
$ Tt = $ result * 222;
// Echo $ tt;
If (! Checkpass ($ tt, $ action, $ db_name, $ table_name_control, $ id_link ))
{
If ($ action = "delete ")
Echo "Sorry, you have no permission to delete the message !!!
";
Else if ($ action = "huifu ")
Echo "Sorry, you cannot recover it now. now only the moderator has this permission !!!
";
Else
Echo "Sorry, you have no permission to manage message books !!! ";
Exit;
}
}
If ($ action = "delete ")
{
// Printf ("delete ");
// Echo $ key_liuyan;
$ Str_ SQL = "delete from $ table_name where key_liuyan = $ key_liuyan ";
$ Re = mysql_db_query ($ db_name, $ str_ SQL, $ id_link );
If (! $ Re)
{
Echo "deletion error ";
}
Else
{
Echo "successfully deleted ";
Echo"";
Echo" Post";
Echo" ";
Echo" ";
Echo"
";
Echo"
The reply is successful. the message content is displayed automatically ";
Echo"
";
Echo "if your browser does not return to the homepage of the message book automatically, click here ";
Echo"
";
}
}
Else if ($ action = "huifu ")
{
// Printf ("huifu ");
// Echo $ key_liuyan;
?>
}
Else if ($ action = "OK ")
{
$ Key = $ arr_request ['key'];
$ Huifuold = $ huifu;
$ Time = date ('Y/m/d H: I: s ');
$ Time = '('. $ time .')
';
$ Huifuold = $ time. $ huifuold;
$ Huifu_ OK = computer_message ($ huifuold, $ hang_zifu_number );
If (strlen ($ key) = 0)
{Echo "error ";
Exit;
}
$ Str_ SQL = "update $ table_name set huifu_biaozi = 1,
Huifu = '$ huifu_ OK' where key_liuyan = $ key ";
// Echo $ str_ SQL;
$ Re = mysql_db_query ($ db_name, $ str_ SQL, $ id_link );
If (! $ Re)
{
Echo "update error ";
}
Else
{
Echo "reply successful ";
Echo"";
Echo" Post";
Echo" ";
Echo" ";
Echo"
";
Echo"
The reply is successful. the message content is displayed automatically ";
Echo"
";
Echo "if your browser does not automatically return to the homepage of the message book ,?
Click here to return .";
Echo"
";
Exit;
}
}
Else
Printf ("error ");
?>
[This article is copyrighted by the author and osuo. if you need to reprint it, please indicate the author and its source]