Results 1 to 3 of 3

Thread: css image

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Feb 2006
    Location
    From the UK
    Posts
    422

    css image

    hi, im trying to put something in the top right of my page.

    however i have a logo in the center:

    HTML Code:
    <ul class="right">
    <li><a href="login.php">login</a></li>
    </ul>
    <center>
    <a href="http://www.site.co.uk"><img src="images/site.png" /></a>
    this is my css:

    HTML Code:
    #top ul.right {
    	float:right;
    	font: 11px Arial, Verdana, Helvetica, sans-serif;
    }

    at the moment the 'login' text in the top right nudges the image a little to the left so that it is no longer strictly centred.

    how can i change it so that the 'login' text sits in the top right but the image is still centred without being nudged over..?

    thanks;

  2. #2
    coder. Lord Orwell's Avatar
    Join Date
    Feb 2001
    Location
    Elberfeld, IN
    Posts
    7,628

    Re: css image

    i've always seen this done with tables and you assign the correct table cell a background image. I am no css guru, but i also saw some myspace code once that used position:absolute and then had x and y coordinates with it.
    My light show youtube page (it's made the news) www.youtube.com/@lightsofelberfeld
    Contact me on the socials www.facebook.com/lordorwell

  3. #3
    Hyperactive Member
    Join Date
    Dec 2001
    Location
    Dublin, Ireland
    Posts
    262

    Re: css image

    Try wrapping your image in a div with a style setting of

    clear:both;

    Also note that the center tag is now deemed consigned to the stone age.

Posting Permissions

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



Click Here to Expand Forum to Full Width