Home >Web Front-end >CSS Tutorial >How to set borders in css
How to set the border in css: 1. Set the border in a border abbreviation attribute; 2. Set the border style in sequence according to the [border-width], [border-style], and [border-color] attributes.
The operating environment of this tutorial: windows7 system, css3 version, DELL G3 computer.
How to set the border in css:
1. Set the border in a border abbreviation attribute.
<html> <head> <style type="text/css"> p { border: medium double rgb(250,0,255) } </style> </head> <body> <p>Some text</p> </body> </html>
Rendering:
2. Set the border style in sequence according to the border-width, border-style, and border-color attributes.
Example:
<html> <head> <style type="text/css"> p { border-width:medium; border-style:double; border-color:rgb(250,0,255); } </style> </head> <body> <p>Some text</p> </body> </html>
Rendering:
The above is the detailed content of How to set borders in css. For more information, please follow other related articles on the PHP Chinese website!