网页界面设计= =(备忘)
mzc6838吧
全部回复
仅看楼主
level 11
mzc6838
楼主
1楼233
2016年12月29日 09点12分
1
level 11
mzc6838
楼主
判断设备以实现自动跳转
<script>
if(navigator.platform.indexOf('Win32')!=-1){
//pc
//window.location.href="电脑网址";
}else{
//shouji
window.location.href="手机网址";
}
</script>
2016年12月29日 09点12分
2
level 11
mzc6838
楼主
手机界面自适应方式
加在<head></head>之间
向浏览器声明该网页为移动设备自适应网页的meta标签为:
<meta name="viewport" content="width=device-width,height=device-height,inital-scale=1.0,maximum-scale=1.0,user-scalable=no;">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="format-detection" content="telephone=no">
2016年12月29日 09点12分
4
level 11
mzc6838
楼主
用作备忘
http://jingyan.baidu.com/article/a3761b2b80b1361576f9aa81.html
http://jingyan.baidu.com/article/cdddd41c61823e53cb00e198.html
2016年12月29日 10点12分
5
level 11
mzc6838
楼主
CSS 网页背景自动拉♂伸
<head></head>之间加入
<style type= "text/css">
body {
background-attachment: fixed;
background-image: url(index.files/bg.png);
background-size: cover;
overflow: hidden;
background-repeat: no-repeat;
}
</style>
2017年03月07日 03点03分
6
1