Use div css to solve the problem of horizontal scroll bars_Experience exchange

WBOY
Release: 2016-05-16 12:07:38
Original
1620 people have browsed it

A very depressing question, take a look at the code I originally wrote:


[Ctrl A Select all Note:If you need to introduce external Js, you need to refresh it to execute]

A horizontal scroll bar actually appeared. The problem is that the width I defined is only 950px. ! Finally, with the help of netizens, I discovered the reason:

1 You can directly change the css of the body to:
body{width:990px; margin:0; padding:0;}
2 You can add:

* {margin:0;padding:0;}The running effect after adding:

[Ctrl A Select all Note:If you need to introduce external Js, you need to refresh it to execute]
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
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!