Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New Coder DjDanHayden's Avatar
    Join Date
    Nov 2008
    Location
    Ireland
    Posts
    55
    Thanks
    18
    Thanked 0 Times in 0 Posts

    Help Needed Please

    Hi everyone..

    Here is my website : http://battlestation.info/home/index.php


    As you can see im working on the css, but im stuck and need your help.

    Look about halfway down the page there is 3 usernames and avatars, they are going below one another and i need them to go beside one another and across the black box. (I know, Basic but i just cant get it lol)

    Here is the html and css

    Html/php:

    PHP Code:
    <div id="newpeople"><div class="marg">

      <div class="padd">
    <?
    $con 
    $db->query("SELECT * FROM " TABLE_PREFIX "user ORDER BY userid DESC LIMIT 0,5");
        while(
    $newusers $db->fetch_array($con))
        {


    $getavatar=mysql_query("SELECT * FROM " TABLE_PREFIX "customavatar WHERE userid='$newusers[userid]'");
    $getavatar=mysql_fetch_array($getavatar);

    if(
    $getavatar[userid]){
    $avatar="./image.php?u=$newusers[userid]&dateline=$getavatar[dateline]&type=thumb";
    } else {
    $avatar="./theme/images/noavatar.jpg";
    }

        echo 
    "<div class='people'><a href='./member.php?u=$newusers[userid]'><img height='60' width='60' src='$avatar' alt=''><span>$newusers[username]</span></a></div>";
    }



    ?>
      </div>
    </div></div>


    CSS:

    #newpeople {position:absolute; top:785px; left:396px; width:899px; height:110px; background:transparent url(/home/theme/images/bg_newpeople.gif) repeat top left;}

    #newpeople .marg {margin:7px 10px 10px 7px;}

    #newpeople .padd {position:absolute; top:10px; left:10px; padding:10px 0; background:transparent url(/home/theme/images/bg_roundedtop.gif) no-repeat top left;}

    #newpeople .people {margin-bottom:5px;}

    #newpeople .people img {padding:5px;}

    #newpeople .people a:link, #newpeople .people a:active, #newpeople .people a:visited {color:#EEC201;}

    #newpeople .people a:hover {text-decoration:underline;}

    #newpeople span {display:block; clear:both;}

    Thanks in advance, and thats to whoever helps

  • #2
    Regular Coder
    Join Date
    Jan 2009
    Posts
    193
    Thanks
    0
    Thanked 20 Times in 20 Posts
    When I click the link it asks for a username and password to access the site.

  • Users who have thanked skywalker2208 for this post:

    DjDanHayden (08-06-2010)

  • #3
    New Coder DjDanHayden's Avatar
    Join Date
    Nov 2008
    Location
    Ireland
    Posts
    55
    Thanks
    18
    Thanked 0 Times in 0 Posts
    Oh yea sorry...

    Try now...

  • #4
    Regular Coder
    Join Date
    Jan 2009
    Posts
    193
    Thanks
    0
    Thanked 20 Times in 20 Posts
    Add a float: left to the css below.

    Code:
    #newpeople .people {
    margin-bottom:5px;
    }
    I would also suggest to not use position, top, left, right and bottom for designing page layouts.

  • Users who have thanked skywalker2208 for this post:

    DjDanHayden (08-06-2010)


  •  

    Posting Permissions

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