判断是不是手机站
<script type="text/javascript">
try {var urlhash = window.location.hash;if (!urlhash.match("fromapp"))
{if ((navigator.userAgent.match(/(iPhone|iPod|Android|ios|iPad)/i)))
{window.location="[!--news.url--]e/wap/";}}}
catch(err)
{
}</script>
============
<?php
$public_r[home]=1;
?>
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript">
try {var urlhash = window.location.hash;if (!urlhash.match("fromapp"))
{if ((navigator.userAgent.match(/(iPhone|iPod|Android|ios|iPad)/i)))
{window.location="[!--news.url--]e/wap/";}}}
catch(err)
{
}</script>
<meta name="mobile-agent" content="format=xhtml;url=[!--news.url--]e/wap/">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|