Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/spring-boot/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Css 内部背景图像<;第节>;韩元';t显示_Css_Layout_Background Image - Fatal编程技术网

Css 内部背景图像<;第节>;韩元';t显示

Css 内部背景图像<;第节>;韩元';t显示,css,layout,background-image,Css,Layout,Background Image,在我的分区内,标签(下面的代码)不会显示在页面上。我想知道为什么 HTML: 另外,当我调整浏览器窗口的大小时,我希望我的图片按比例缩放(宽度和高度)。正文宽度上缺少分号语法错误 html{ 宽度:100%; 高度:1230px; } 身体{ 宽度:90%; 身高:100%; } 部分{ 宽度:100%; 身高:19.19%; 背景图像:url(“http://s12.postimg.org/xx34q95m3/header.jpg"); 背景大小:100%100%; 背景重复:无重复; }

在我的分区内,标签(下面的代码)不会显示在页面上。我想知道为什么

HTML:


另外,当我调整浏览器窗口的大小时,我希望我的图片按比例缩放(宽度和高度)。

正文宽度上缺少分号语法错误

html{
宽度:100%;
高度:1230px;
}
身体{
宽度:90%;
身高:100%;
}
部分{
宽度:100%;
身高:19.19%;
背景图像:url(“http://s12.postimg.org/xx34q95m3/header.jpg");
背景大小:100%100%;
背景重复:无重复;
}

使用此HTML- 有些东西应该写在节中,css正文中也缺少分号

<!doctype html>
<html lang="pl">
<head><title>Strona</title>
<meta charset="utf-8">
<link href="style.css" rel="stylesheet" screen="media,projection">
</head>
<body>
<section>Saurabh Singh Mehra</section>
</body>
</html>

正文宽度上缺少分号语法错误Ok,分号my bad,但现在我希望在调整浏览器窗口大小时,图片按比例缩放(宽度和高度)。但只有宽度似乎在缩小,而高度保持不变……这使得图片变形。IMG标签似乎是答案,但我不希望IMG标签OK,分号my bad,但现在我希望我的图片在调整浏览器窗口大小时按比例缩放(宽度和高度)。但只有宽度似乎在缩小,而高度保持不变……这使得图片变形。IMG标签似乎是答案,但我不想要IMG标签,我想要背景,这样我就可以在平板电脑样式中,在该部分下的移动样式将header.jpg picture替换为较小的文件使用图像高度设置为auto我刚刚将图像高度设置为auto,它可以工作,这是一个奇迹,我认为背景属性不能按比例改变。。。
html {
 width:100%;
 height:1230px;
}
body {
    width:90%
    height:100%;
}
section {
    width:100%;
    height:19.19%;
    background:url(header.jpg); *this path should work because the file is on my hard drive, this is not the issue of the path..
    background-size:100% 100%;
    background-repeat:no-repeat;
}
<!doctype html>
<html lang="pl">
<head><title>Strona</title>
<meta charset="utf-8">
<link href="style.css" rel="stylesheet" screen="media,projection">
</head>
<body>
<section>Saurabh Singh Mehra</section>
</body>
</html>
html {
 width:100%;
 height:1230px;
}
body {
    width:90%;
    height:100%;
}
section {
    width:100%;
    height:19.19%;
    background:url(header.jpg);
    background-size:100% 100%;
    background-repeat:no-repeat;
}