2 Replies Latest reply: Oct 1, 2010 9:47 AM by upstart1762 RSS

    Odd link color / indenting paragraph

    upstart1762 Community Member

      I wonder if someone could have a look at the following HTML file (www.upstartstudio.com/layout2.html) and answer a few questions: 1- When previewing in browser, one of my nav links is turning purple (see attached image). This has happened to me several times but I can't nail down why. 2- Why is my text indenting, and how do I stop it from doing so? 3- Why is my nav breaking to 2 lines in DW(see attached image)? It looks fine when previewed in browser, but it's difficult to design with it breaking to 2 lines. Is there any way to avoid this? Thanks in advance!

       

       

       

      LinkColor.pngNavStack.png

        • 1. Re: Odd link color / indenting paragraph
          bemdesign Community Member

          Here's several hints:

           

          1. All browsers have a default styling they apply in rendering HTML.
          2. This default styling often makes visted links purple.
          3. The browser default styling also has padding and margins which may cause text indentations.

           

           

          And you can override these styling defaults through a CSS reset.

           

          *{padding:0; margin:0; border:none; text-decoration:none; color:#FFFFFF; /*and whatever else you want the default to be in your CSS*/}

           

          EDIT: to override the link styling you will need to create your own default link styling by some CSS like this:

          a, a:link{

          /*change the basic anchor tag styling*/

          }

          a:visited{

          /*change rendering of visited links*/

          }

          a:hover{

          /*change rendering of links on hover*/

          }

          a:active{

          /*change the rendering of active links (not really used a lot but good to include anyway)*/

          }

          --> end edit

           

          As for looking weird in Dreamweaver - don't trust design view. The only view that counts is the one rendered in a browser! Don't use Dreamweaver as a what-you-see-is-what-you-get HTML editor - there is no such thing and anything that claims to be is... misleading... at best. Learn to work with code and test in the browser.

           

          Hope this helps.

           

          Message was edited by: bemdesign

          • 2. Re: Odd link color / indenting paragraph
            upstart1762 Community Member

            1. Visited links. Got it. Fixed.

            2. Text indent - Just found that I had 10px padding on the <p>. So.. I'm an idiot.

            3. Don't trust design view. Got it. Found I can get it to look right in Design view by wrapping nav in a div and setting width. But that's unnecessary code.

             

            Big help. Thank you.