Results 1 to 5 of 5

Thread: Logo help

  1. #1
    Join Date
    Mar 2008
    Posts
    19
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Default Logo help

    Hi,

    Not sure if this is the right place to post this question but I'll give it a go. I'm trying to find out how I include a small logo in front of the URL but can't find how I do it. Can anyone help me out with the code?

  2. #2
    Join Date
    Jul 2006
    Location
    just north of Boston, MA
    Posts
    1,806
    Thanks
    13
    Thanked 72 Times in 72 Posts

    Default

    in front as in to the left side or in front as in directly over the text

    you can do both with css. the former can be done with a background image, while the latter requires an additional image tag

    HTML Code:
    <ul id="menu">
         <li>Some Link</li>
         <li>Some Other Link</li>
         <li>Boring Link</li>
    </ul>
    Code:
    ul#menu li {
    /* reset defaults */
         list-style-type: none;
         margin: 0;
         padding: 0;
    /* apply left-aligned logo */
         padding-left: 1em;
         background: url('/path/to/image.jpg') no-repeat top left;
    }
    that will apply the same image to all of the list items, to get a separate image per list item, you can use almost the same code, with a few minor updates

    HTML Code:
    <ul id="menu">
         <li id="link1">Some Link</li>
         <li id="link2">Some Other Link</li>
         <li id="link3">Boring Link</li>
    </ul>
    Code:
    ul#menu li {
    /* reset defaults */
         list-style-type: none;
         margin: 0;
         padding: 0;
    /* apply left-aligned logo */
         padding-left: 1em;
    }
    ul#menu li#link1 {background: url('/path/to/image1.jpg') no-repeat top left;}
    ul#menu li#link2 {background: url('/path/to/image2.jpg') no-repeat top left;}
    ul#menu li#link3 {background: url('/path/to/image3.jpg') no-repeat top left;}
    note that I still kept the padding in the original declaration... it will be inherited to all the list items still... the only thing that is different is that you want each list item to have its own unique image.

    you can do this same process with "groups" of links too... just replace id with class (html) and # with . (css) respectively

  3. #3
    Join Date
    Mar 2008
    Posts
    19
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Default

    If you look at the address bar of your browser now, can you see the green 'd' logo that dynamic drive has there and in the browser tab (I-Explorer)?
    I want to put my little logo there.

    I didn't make much sense of what you wrote, can you explain it in slightly simpler terms for me?

    Much appreciated!

  4. #4
    Join Date
    Sep 2006
    Location
    St. George, UT
    Posts
    2,769
    Thanks
    3
    Thanked 157 Times in 155 Posts

    Default

    That is a favicon. DD has a tool for making these located here:
    http://tools.dynamicdrive.com/favicon/

    Hope this helps.
    "Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music." - Kristian Wilson, Nintendo, Inc, 1989
    TheUnlimitedHost | The Testing Site | Southern Utah Web Hosting and Design

  5. The Following User Says Thank You to thetestingsite For This Useful Post:

    Marcus-Hill (04-03-2008)

  6. #5
    Join Date
    Mar 2008
    Posts
    19
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Default

    Thetestingsite, once again you are a legend.

    Many thanks!

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •