function geturl(){//获得完整的URL
if(count($_GET)){
foreach ($_GET as $key=>$value){
$str.=$key."=".$value."&";
}
$str=substr($str,0,-1);
if(strlen($str)){
$url="http://".$_SERVER['HTTP_HOST'].$_SERVER['SCRIPT_NAME']."?".$str;
}else{
$url="http://".$_SERVER['HTTP_HOST'].$_SERVER['SCRIPT_NAME'];
}
}
return $url;
}//获得完整的URL