define(OPEN_AD,"0");//跳转页广告开关,1表示开,0表示关.
require_once('config.inc.php');
if(API_KEY==""){
echo "请修改config.inc.php API_KEY参数,
点击注册申请API";
}
if(count($_GET['url'])>0){
//$url = "http://1dnet.net/index.php?api=1&return_url_text=1&lOngUrl=".$_GET['url'];
$url="http://qita.in/app.php?api=".API_KEY."&type=noad&url=".$_GET['url'];
$ch = curl_init();
$timeout = 5;
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $timeout);
//在需要用户检测的网页里需要增加下面两行
//curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_ANY);
//curl_setopt($ch, CURLOPT_USERPWD, US_NAME.":".US_PWD);
$cOntents= curl_exec($ch);
eregi('http://qita.in/(.*)',$contents,$new);
curl_close($ch);
if(strlen($contents)<8){
$shorturl="请输入正确的短网址";
}
$shorturl=SITE."/$new[1]";
//echo &#39;&#39;;
}
?>
&#65279;
/index.php" method="get" id="post_form">
echo &#39;
&#39;.$_GET[&#39;url&#39;].&#39; | &#39;;
?>