解析 css 文本媒体查询
resolving css text media query
我正在努力使我的文本-电影、电视节目、游戏具有响应性。我应该怎么办?我尝试了媒体查询,但我想我弄错了。
<!DOCTYPE html>
<html>
<head>
<title>Papaya | Home</title>
<link href='https://fonts.googleapis.com/css?family=Luckiest+Guy' rel='stylesheet' type='text/css'>
<style type="text/css">
.bg {
width: 100%;
height: 110%;
position: absolute;
top: 0;
left: 0;
z-index: -4000;
}
body{
font-family: 'Luckiest Guy', cursive;}
a:hover {color: red;}
a { text-decoration: none; color:white; }
a:visited { text-decoration: none; }
a:hover { text-decoration: none; }
a:focus { text-decoration: none; }
a:hover, a:active { text-decoration: none; }
#one {
position: fixed;
top:180px;
left:200px;
}
#two {
position: fixed;
top:180px;
left:570px;
}
#three {
position: fixed;
top:180px;
left:900px;
}
h1{font-size:70px}
}
</style>
</head>
<body >
<div id="one">
<h1><a href="movies.html" style="text-decoration:none">MOVIES</a></h1></div>
<div id="two">
<h1><a href="games.html" style="text-decoration:none">GAMES</a></h1></div>
<div id="three">
<h1><a href="tvshows.html" style="text-decoration:none">TV SHOWS</a></h1></div>
<div align="center"><img src="images/ball.jpg" class="bg" alt="LOADING.."></div>
</body>
</html>
首先,写HTML和CSSn个单独的文件。它被认为是 Web 开发的最佳实践;)然后,为网站添加响应能力的最佳方法是安装 Bootstrap。
将其复制并粘贴到 html 文档的开头:
这是一个 CDN(内容交付系统)link。它将从他们的网站中提取 bootstrap 功能,并允许您为您的网站添加响应能力。
这是 Bootstrap 文档 link:
http://getbootstrap.com/getting-started/
我的回答可能看起来有点冗长和复杂,但事实并非如此。这就是当今专业人士和公司如何打造现代化、响应迅速的网站的方式!希望这可以帮助。
我正在努力使我的文本-电影、电视节目、游戏具有响应性。我应该怎么办?我尝试了媒体查询,但我想我弄错了。
<!DOCTYPE html>
<html>
<head>
<title>Papaya | Home</title>
<link href='https://fonts.googleapis.com/css?family=Luckiest+Guy' rel='stylesheet' type='text/css'>
<style type="text/css">
.bg {
width: 100%;
height: 110%;
position: absolute;
top: 0;
left: 0;
z-index: -4000;
}
body{
font-family: 'Luckiest Guy', cursive;}
a:hover {color: red;}
a { text-decoration: none; color:white; }
a:visited { text-decoration: none; }
a:hover { text-decoration: none; }
a:focus { text-decoration: none; }
a:hover, a:active { text-decoration: none; }
#one {
position: fixed;
top:180px;
left:200px;
}
#two {
position: fixed;
top:180px;
left:570px;
}
#three {
position: fixed;
top:180px;
left:900px;
}
h1{font-size:70px}
}
</style>
</head>
<body >
<div id="one">
<h1><a href="movies.html" style="text-decoration:none">MOVIES</a></h1></div>
<div id="two">
<h1><a href="games.html" style="text-decoration:none">GAMES</a></h1></div>
<div id="three">
<h1><a href="tvshows.html" style="text-decoration:none">TV SHOWS</a></h1></div>
<div align="center"><img src="images/ball.jpg" class="bg" alt="LOADING.."></div>
</body>
</html>
首先,写HTML和CSSn个单独的文件。它被认为是 Web 开发的最佳实践;)然后,为网站添加响应能力的最佳方法是安装 Bootstrap。 将其复制并粘贴到 html 文档的开头:
这是一个 CDN(内容交付系统)link。它将从他们的网站中提取 bootstrap 功能,并允许您为您的网站添加响应能力。
这是 Bootstrap 文档 link:
http://getbootstrap.com/getting-started/
我的回答可能看起来有点冗长和复杂,但事实并非如此。这就是当今专业人士和公司如何打造现代化、响应迅速的网站的方式!希望这可以帮助。