<script type="text/javascript">
function IsPC() {
var userAgentInfo = navigator.userAgent;
var Agents = ["Android", "iPhone","SymbianOS", "Windows Phone","iPad", "iPod"];
var flag = true;
for (var v = 0; v < Agents.length; v++) {
if (userAgentInfo.indexOf(Agents[v]) > 0) {
flag = false;
break;
}
}
if (flag){
document.write("移动端")
}else{
document.write("电脑端")
}
}
IsPC();
</script>
function IsPC() {
var userAgentInfo = navigator.userAgent;
var Agents = ["Android", "iPhone","SymbianOS", "Windows Phone","iPad", "iPod"];
var flag = true;
for (var v = 0; v < Agents.length; v++) {
if (userAgentInfo.indexOf(Agents[v]) > 0) {
flag = false;
break;
}
}
if (flag){
document.write("移动端")
}else{
document.write("电脑端")
}
}
IsPC();
</script>
<%
Dim HUA
HUA=Request.ServerVariables("Http_User_Agent")
If InStr(HUA,"Android")+InStr(HUA,"iPhone")+InStr(HUA,"SymbianOS")+InStr(HUA,"Windows Phone")+InStr(HUA,"iPad")+InStr(HUA,"iPod")>0 Then%>
<div style="position:fixed;bottom:0px;top:auto;">
</div>
<%Else%>
<div style="position:fixed; right: 0px; width: 250px; height: 250px; z-index: 2; bottom:1px" id="layer2">
</div>
<%End If%>
Dim HUA
HUA=Request.ServerVariables("Http_User_Agent")
If InStr(HUA,"Android")+InStr(HUA,"iPhone")+InStr(HUA,"SymbianOS")+InStr(HUA,"Windows Phone")+InStr(HUA,"iPad")+InStr(HUA,"iPod")>0 Then%>
<div style="position:fixed;bottom:0px;top:auto;">
</div>
<%Else%>
<div style="position:fixed; right: 0px; width: 250px; height: 250px; z-index: 2; bottom:1px" id="layer2">
</div>
<%End If%>
[本日志由 tiancao1001 于 2015-04-17 09:33 PM 编辑]
|
暂时没有评论
发表评论 - 不要忘了输入验证码哦! |