How to disable sliding in css

coldplay.xixi
Release: 2023-01-05 16:13:23
Original
15398 people have browsed it

How to disable sliding in css: 1. Add [scroll="no"] to [] to hide the scroll bar; 2. Refers to when the width or height of the browser window is larger than the width or height of the page. When it is high, the scroll bar will not be displayed; 3. Add [style="overflow-x:hidden"] to [].

How to disable sliding in css

The operating environment of this tutorial: windows7 system, css3 version, DELL G3 computer.

How to disable sliding in css:

1. Completely hide

Add scroll="no" to to hide scrolling Bar;

<boby scroll="no">
Copy after login

2. Hide when not needed

means that when the width or height of the browser window is greater than the width or height of the page, the scroll bar will not be displayed;

Otherwise, it will be displayed;

<boby scroll="auto">
Copy after login

3. Style sheet method

Add style="overflow-x:hidden" in , to hide the horizontal scroll bar;

Add style="overflow-y:hidden" to hide the vertical scroll bar.

Add

<style>
html { overflow-x:hidden; }
</style>
Copy after login

to the included page. Related learning recommendations: css tutorial

The above is the detailed content of How to disable sliding in css. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
css
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