Home > Web Front-end > HTML Tutorial > 为何页面内容和网页边缘有空隙_html/css_WEB-ITnose

为何页面内容和网页边缘有空隙_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:28:14
Original
2165 people have browsed it

为何页面内容和网页边缘有空隙:
这个问题一般在新人中出现,就是网页内容和网页边缘有空隙。这里就不进行代码演示了,因为body元素默认情况下是具有外边距和内边距的只要将它们的值分别设置为0即可。
代码如下:

body{  margin:0px;  padding:0px;}
Copy after login

现在正规的开发中,一般采用样式重置代码,这里不多介绍,具体可以参阅下面的文章。
样式重置可以参阅css预重置样式代码一章节。

原文地址是:http://www.softwhy.com/forum.php?mod=viewthread&tid=15643

更多内容可以参阅:http://www.softwhy.com/divcss/

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template