使我的网站可扩展到移动设备

杰克德

尝试将我的网站扩展到移动设备时,不允许使用任何框架。

我想在移动设备上以彼此下面的块预览它吗?我该怎么做,因为我的文字会与我的图像混合,并且导航栏链接会变得混乱并相互滑动?

屏幕变小时,我使用响应式导航栏将其读入汉堡菜单,以读取内容。

视口设置为: <meta name="viewport" content="width=device-width, initial-scale=1">

* {
    padding: 0;
    margin: 0;
}
body, html {
    height: 100%;
    font-family: Camingo, sans-serif;
}

.bg {
    /* The image used */
    background-image: url("https://jackdijkema.000webhostapp.com/pics/skrrrt.jpg");
    /* Full height */
    height: 100%;
    /* Center and scale the image nicely */
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    position: relative;
}
.AboutMe {
    /* The image used */
    background-color: white;
    /* Full height */
    height: 50%;
    /* Center and scale the image nicely */
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    position: relative;
}
.Hoofdnav {
    font-family: Camingo, sans-serif;
    font-size: 25px;
    width: 100%;
    position: absolute;
    bottom: 100px;
    font-weight: 300;
}

.Hoofdnav li {
    display: inline-block;
    width: 33.3%;
    text-align: center;
}

.Hoofdnav ul {
    letter-spacing: 4px;
    list-style-type: none;
    margin: 0 auto;
    width: 30%;
}

.Hoofdnav a {
    color: white;
    text-decoration: none;
}
.Hoofdnav a:hover {
    font-weight: bold;
    text-outline: white 2px;
}
.AboutMe h1  {
    font-family: Camingo;
    text-align: center;
    font-size: 20px;
    font-weight: 700;
    margin-top: 3% ;
    text-transform: uppercase;
/*    text-decoration: underline;*/
    position:absolute;
    margin-left: 25%;
}
.AboutMe p {
    font-family: Camingo, sa;
    text-align: left;
    margin-top: -18% ;
    margin-left: 25%;
    font-size: 19px;s

}
.AboutMe img {
    margin-top: 1.5%;
    margin-left: 5%;
}
<!DOCTYPE html>
<html lang="nl">

<head>
	<meta charset="UTF-8">
	<title>Jack Dijkema</title>
	<link href="CSS/main.css" rel="stylesheet" />
	<link rel="stylesheet" href="CSS/header.css" />
	<link href='https://fonts.googleapis.com/css?family=Permanent+Marker:400' rel='stylesheet' type='text/css'>
	<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<link rel="apple-touch-icon" sizes="180x180" href="/pics/apple-touch-icon.png">
	<link rel="icon" type="image/png" sizes="32x32" href="/pics/favicon-32x32.png">
	<link rel="icon" type="image/png" sizes="16x16" href="/pics/favicon-16x16.png">
	<link rel="manifest" href="/pics/site.webmanifest">
	<link rel="mask-icon" href="/pics/safari-pinned-tab.svg" color="#5bbad5">
	<link rel="shortcut icon" href="/pics/favicon.ico">
	<meta name="msapplication-TileColor" content="#da532c">
	<meta name="msapplication-config" content="/pics/browserconfig.xml">
	<meta name="theme-color" content="#ffffff">
</head>
<body>
	<div class="bg"></div>
<hr>
	<div class="AboutMe">
		<h1>ABOUT</h1>
   			<img src="https://jackdijkema.000webhostapp.com/pics/rsz_150982648_370567113534046_8331947271073836645_n%20(1).jpg" alt="Picture of Jack Dijkema About me section">
				<p>
				Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque sit amet hendrerit turpis.<br> Mauris commodo
				est ex, ac convallis tellus feugiat ac.<br>
				Praesent sit amet arcu quis elit pulvinar rhoncus.<br> Proin viverra lacinia ante, at interdum magna posuere eget.
				Cras rhoncus a neque ac scelerisque.<br> Pellentesque habitant morbi tristique senectus.
				</p>
			</div>
<div class="myProjects">
	<footer>
	Jack Dijkema Copyright 2019 - 
</footer>
</div>
<nav class="Hoofdnav">
		<ul>
			<li><a href="index.html">AboutMe</a></li><li><a href="index.html">Projects</a></li><li><a  rel="noopener" target="_blank" href="pdf/Jack%20Dijkema%20CV.pdf">CV</a></li>
		</ul>
</nav>
</body>
</html>

I also uploaded the whole website to:
https://jackdijkema.000webhostapp.com/

If u scale it to mobile device everything gets messed up.
桑lac

我建议阅读W3Schools上的Wiki。

本质上,您需要做的是调查CSS中的媒体查询,因为它允许您在屏幕达到特定大小时设置不同的样式。

您也可以查看此示例响应头。使用媒体查询可以在不使用Bootstrap或框架的情况下进行响应式设计。

本文收集自互联网,转载请注明来源。

如有侵权,请联系[email protected] 删除。

编辑于
0

我来说两句

0条评论
登录后参与评论

相关文章

来自分类Dev

如何创建从移动设备到桌面网站的重定向?

来自分类Dev

为什么我的容器不能扩展到包含我的内容?

来自分类Dev

扩展移动设备的布局

来自分类Dev

嵌入在对话框中的弹出窗口是否可以(以可裁剪的方式)扩展到设备窗口边框?

来自分类Dev

将网站重定向到移动网站以及从移动设备重定向到桌面?

来自分类Dev

扩展到defsetf的Defmacro

来自分类Dev

如何将UICollectionViewCell的可触摸区域扩展到其范围之外?

来自分类Dev

网站页脚在我的移动设备上不稳定

来自分类Dev

响应式网站:无法在移动设备上正确扩展

来自分类Dev

是否有任何可空注释隐式扩展到泛型类型?

来自分类Dev

如何使可滚动的div在滚动并单击时扩展到最大高度

来自分类Dev

4x4正方形网格,可扩展到最大宽度

来自分类Dev

背景色未扩展到可滚动div的底部

来自分类Dev

背景色未扩展到可滚动div的底部

来自分类Dev

背景色未扩展到可滚动div的底部

来自分类Dev

背景色未扩展到可滚动div的底部

来自分类Dev

哪种思维导图软件可扩展到数千个节点?

来自分类Dev

扩展移动设备的布局

来自分类Dev

将网站重定向到移动网站以及从移动设备重定向到桌面?

来自分类Dev

为什么GridLayout中的GridView会扩展到设备高度以下(GridLayout)?

来自分类Dev

您可以通过调制解调器将网络扩展到特定设备吗?

来自分类Dev

带有嵌入式脚本的SVG,可扩展到浏览器的可用空间

来自分类Dev

响应式网站:无法在移动设备上正确扩展

来自分类Dev

我的网站在移动设备上显示为桌面

来自分类Dev

.Net 4.5 TCP Server可扩展到数千个连接的客户端

来自分类Dev

使用reduce将源对象的可枚举属性扩展到目标对象

来自分类Dev

进入移动视图时,子元素扩展到父div外部

来自分类Dev

我的自适应网站无法在移动设备上运行

来自分类Dev

为什么我的扩展磁贴会扩展到整个屏幕

Related 相关文章

  1. 1

    如何创建从移动设备到桌面网站的重定向?

  2. 2

    为什么我的容器不能扩展到包含我的内容?

  3. 3

    扩展移动设备的布局

  4. 4

    嵌入在对话框中的弹出窗口是否可以(以可裁剪的方式)扩展到设备窗口边框?

  5. 5

    将网站重定向到移动网站以及从移动设备重定向到桌面?

  6. 6

    扩展到defsetf的Defmacro

  7. 7

    如何将UICollectionViewCell的可触摸区域扩展到其范围之外?

  8. 8

    网站页脚在我的移动设备上不稳定

  9. 9

    响应式网站:无法在移动设备上正确扩展

  10. 10

    是否有任何可空注释隐式扩展到泛型类型?

  11. 11

    如何使可滚动的div在滚动并单击时扩展到最大高度

  12. 12

    4x4正方形网格,可扩展到最大宽度

  13. 13

    背景色未扩展到可滚动div的底部

  14. 14

    背景色未扩展到可滚动div的底部

  15. 15

    背景色未扩展到可滚动div的底部

  16. 16

    背景色未扩展到可滚动div的底部

  17. 17

    哪种思维导图软件可扩展到数千个节点?

  18. 18

    扩展移动设备的布局

  19. 19

    将网站重定向到移动网站以及从移动设备重定向到桌面?

  20. 20

    为什么GridLayout中的GridView会扩展到设备高度以下(GridLayout)?

  21. 21

    您可以通过调制解调器将网络扩展到特定设备吗?

  22. 22

    带有嵌入式脚本的SVG,可扩展到浏览器的可用空间

  23. 23

    响应式网站:无法在移动设备上正确扩展

  24. 24

    我的网站在移动设备上显示为桌面

  25. 25

    .Net 4.5 TCP Server可扩展到数千个连接的客户端

  26. 26

    使用reduce将源对象的可枚举属性扩展到目标对象

  27. 27

    进入移动视图时,子元素扩展到父div外部

  28. 28

    我的自适应网站无法在移动设备上运行

  29. 29

    为什么我的扩展磁贴会扩展到整个屏幕

热门标签

归档