• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 7. Border and Margin Controls > Setting an Element's Border

Setting an Element's Border

To set any of the border attributes for all four sides of the box simultaneously, CSS provides the border property (Code 7.3). You can use border to set width, style, and/or color (Figure 7.4). You can also set the element's border on each side of the box individually (see the sidebar " Setting Borders on a Side " in this section).

Code 7.3. You can set all the border's attributes in one definition for all four sides, or you can set them individually for each side (see the sidebar " Setting Borders on a Side ").



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint