EMLOG 手机QQ自动跳转到浏览器PHP代码
转载请注明本文链接:https://blog.l9s.cc/.html [生成短网址]
<?php $conf['qqjump']=1; if(strpos($_SERVER['HTTP_USER_AGENT'], 'QQ/')!==false && $conf['qqjump']==1){$a='http://'.$_SERVER['SERVER_NAME'].':'.$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"]; echo '<!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>请使用浏览器打开</title> <script src="https://open.mobile.qq.com/sdk/qqapi.js?_bid=152"></script> <script type="text/javascript"> mqq.ui.openUrl({ target: 2,url: "'.$a.'"}); </script> </head> <body></body></html>';exit;} ?>
以下教程开始,已亲测。 适合个类型网站,对于已经红的域名简直就是如神助攻!
请放在</head>上方即可: