php学习--auth授权

+展开
-PHP
$auth=false;
$user=$_SERVER['PHP_AUTH_USER'];
$pwd=$_SERVER['PHP_AUTH_PW'];
if(isset($user)&&isset($pwd)&&$user==strrev($pwd))$auth=true;

if(!$auth)
{
header('www-authenticate:basic realm="top secret files"');
header("http/1.0 401 unauthorized");
}
echo $user,"",$pwd;

加支付宝好友偷能量挖...


原创文章,转载请注明出处:php学习--auth授权

评论(0)Web开发网
阅读(120)喜欢(0)PHP/apache/Perl