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

Lesson 18. Creating a Site Header > Styling the <image> Element

Styling the <image> Element

The image should be set to display: block. This will remove any gaps that appear below it and force the <h1> border-bottom to sit up against it.

The image is nested inside an <a> element. In some browsers this will cause the image to display with a 2-pixel-wide border. To avoid this, the image should be styled with border: 0 as shown in Listing 18.6. The results can be seen in Figure 18.4.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


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