0 Replies Latest reply on Apr 9, 2009 10:06 AM by David_Powers

    Get rid of blue borders around images in links

    David_Powers Adobe Community Professional

      When you use an image as a link, a blue border surrounds the image like this:


      This is because since Dreamweaver CS3, Dreamweaver no longer inserts border="0" in the image (<img>) tag. Although some people will tell you to set the image border to zero in the Property inspector, this is NOT the correct way to do it. Use CSS instead.


      Create the following style rule, either in a <style> block in the <head> of the page, or preferably in an external style sheet:

      a img { border: none; }

      This automatically removes the blue border from ALL images that are used as links. If you use an external style sheet, and link it to all the pages in your site, the same rule affects every image link in your site. This is much more efficient than adding zero to the border property in each individual image.