Search code examples
htmlcssmarginfooter

How do I fit text into footer margins


I know this is probably very simple for most of you but it's kicking my butt. I am building my business's website using Dreamweaver CS6 to edit a template I downloaded from free website templates. The problem that I'm having is that I can't fit the link on the right side of the footer into the footer. I'm not sure if this is an HTML problem or a CSS problem. Here's an example of what I'm talking about:

Left Margin.........Right Margin

Home...About...Gallery...Contacts

It doesn't seem to matter how many links are there, the last one overhangs the footer. I'd appreciate any help you can give me. Thank you.

http://tinypic.com/r/2nvcljq/6

Fiddle

#footer ul.navigation {
float: right;
display: inline-block;
line-height: 24px;
list-style: none;
margin: 0;
padding: 0;
}
#footer ul.navigation li {
float: left;
margin-left: 15px;
}
#footer ul.navigation li:first-child {
margin-left: 0;
}
#footer ul.navigation li a {
color: #ab7d0f;
font: 11px/24px "Oswald";
text-decoration: none;
text-transform: uppercase;
}
#footer ul.navigation li a:hover {
color: #241b18;
}
#footer #footnote {
color: #ab7d0f;
font: 11px/24px "Oswald";
margin: 0;
text-transform: uppercase;
}


<div id="footer">
    <div>
      <div id="links">
        <div class="showroom">

              <p>4885 Wilson Street<br> Victorville, CA 92392<br><br> 702-409-5373<br>
                <br> 
                  <a href="index.html">[email protected]</a>
          </p>
          </div>

        <ul class="navigation">
            <li><a href="index.html">Home</a>
                <a href="about.html">About</a><a href="gallery.html"> Gallery</a>
              <a href="contact.html">Contact</a>
            </li>
        </ul>
        <p id="footnote">
            © Copyright TIBISI, Inc 2013. All Rights Reserved.
      </p>
    </div>
</div>

Solution

  • I suggest to replace current #footer ul.navigation rule with this one

    #footer ul.navigation {
        float: right;
        display: block;
        line-height: 24px;
        list-style: none;
        margin: 0;
        padding: 0 10px 0 0;
    }
    

    Fiddle's and your page's footer don't look the same though.