html模拟手机页面

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>活动预览</title>
<meta name="description" content="">
<meta name="keywords" content="">
<meta name="viewport" content="initial-scale=1, maximum-scale=1">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
	</head>
	<body class="docs-home" ontouchstart="">

    <style type="text/css">
	@media (min-width: 850px){
		.docs-home .phone{
		  	/*margin: 0px 0px;*/ 
		  	margin: 10px auto !important;
		  }
		  
		  .phone:before {
		    content: '';
		    width: 60px;
		    height: 10px;
		    border-radius: 10px;
		    position: absolute;
		     left:50%; 
		    margin-left: -30px;
		    background:#333; 
		    top: 50px;
		}
		  
		  .phone .statusbar {
		    position: absolute;
		    width: 320px;
		    height: 20px;
		   	background:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAoAAAAAoCAIAAADhf9zeAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyhpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMDE0IDc5LjE1Njc5NywgMjAxNC8wOC8yMC0wOTo1MzowMiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c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BcjYKCgjlz5kRHR9t/LxBnlJaWrly50pJ1ZQfMMAwT8g64oaHh4MGDXnpfxmYcfAkYhmFCmsbGRva+7IAZhmEYW7l9+zZ7X4ZhGIaxj4iIiEmTJrVvz5NZGIZhGIZhlOEuaIZhGIZhB8wwDMMw7IAZhmEYhvET/wowADOhvI/6on5eAAAAAElFTkSuQmCC');
		    left: 50%;
		    margin-left: -160px;
		    top: 100px;
		    -webkit-background-size: 100% auto;
		    background-size: 100% auto;
		}
		  
		  .phone:after {
		    content: '';
		    position: absolute;
		    width: 60px;
		    height: 60px;
		    left: 50%;
		    margin-left: -30px;
		    bottom: 20px;
		    border-radius: 100%;
		    box-sizing: border-box;
		    border: 5px solid #333;
		}
	}
	.phone{
		background: #111;
		border-radius: 0px;
		box-shadow: none;
		width: 100%;
		height: 568px;
		padding: 0;
	}
	.docs-home.mui-ios .phone .statusbar,.docs-home.mui-android .phone .statusbar,.docs-home.mui-ios .phone:before,.docs-home.mui-ios .phone:after{
		display: none;
	}
	.phone {
		margin: 0 auto;
		position: relative;
	    background: #111;
	    border-radius: 55px;
	    box-shadow: 0px 0px 0px 2px #aaa;
	    width: 320px;
	    height: 568px;
	    padding: 105px 25px;
	    -webkit-box-sizing: content-box;
	    box-sizing: content-box;
	}
	.phone iframe {
	    width: 320px;
	    height: 100%;
	    display: block;
	    width: 100%;
	    margin-top: 20px;
	}
</style>

		<div class="docs-header">
			<div style="max-width:1024px;margin:0 auto;"> 
				<div class="phone">
					<iframe src="http://m.baidu.com" frameborder="0" scrolling="yes"></iframe>
					<div class="statusbar"></div>
				</div>
			</div>
		</div>
	</body>
</html>

  

posted @ 2017-12-26 09:54  胡一生  阅读(782)  评论(0编辑  收藏  举报