• 本帖最后由 彩虹城 于 2012-4-21 21:49 编辑 *

上图

hostloc

12622

godaddy

12623

实现方法- caching = true;

  • }
  • $ua = strtolower($_SERVER['HTTP_USER_AGENT']);
  • - $uachar = "/(nokia|iphone|android|sony|ericsson|mot|samsung|sgh|lg|philips|panasonic|alcatel|lenovo|cldc|midp|mobile)/i";
  • - if(($ua == '' || preg_match($uachar, $ua))&& !strpos(strtolower($_SERVER['REQUEST_URI']),'wap'))
  • {
  • header( "HTTP/1.1 301 Moved Permanently");
  • - header("Location: mobile/");
  • - }else {
  • - header( "HTTP/1.1 301 Moved Permanently");
  • - header("Location: web/");
  • - }
  • - php?>复制代码

测试地址
http://2.gy/cMMU