Skip to content

Instantly share code, notes, and snippets.

@adison
Created March 14, 2014 01:58
Show Gist options
  • Save adison/9540842 to your computer and use it in GitHub Desktop.
Save adison/9540842 to your computer and use it in GitHub Desktop.
全螢幕網頁,圖片置中
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, maximum=1.0, minimum-scale=1.0">
<!-- width:可設定數值,或者指定為 device-width
height:可設定數值,或者指定為 device-height
initial-scale:第一次進入頁面的初始比例
minimum-scale:允許縮小最小比例
maximum-scale:允許放大最大比例
user-scalable:允許使用者縮放,1 or 0 (yes or no) -->
<title>等待畫面</title>
<style type="text/css">
div.fullscreen{
display:block;
/*set the div in the top-left corner of the screen*/
position:absolute;
top:0;
left:0;
/*set the width and height to 100% of the screen*/
width:100%;
height:100%;
background:url(pic_512x512.png) no-repeat center center;
}
</style>
</head>
<body>
<div class="fullscreen">
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment