Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Fhe is offline
    New to the CF scene
    Join Date
    Jul 2007
    Thanked 0 Times in 0 Posts

    Question Help on creating a simple <Div> please?

    Hi, I am trying to code my own myspace layout useing CSS/HTML the link is here.
    I need to create a new DIV with a transparent background. See the image i have added for more information.


    Im not sure the size the div will need to be.. i think about 150px width and about 300 height im not sure. Can some one please help me create this div? i dont undertand them.

    So far i have this.

    Im not sure about the leftpx ? is that how far its from the VERY left of the web browser or what?


  • #2
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Halle (Saale), Germany
    Thanked 1,053 Times in 1,026 Posts
    Quote Originally Posted by Fhe View Post
    […] is that how far its from the VERY left of the web browser or what?
    Not particularly. The offsets of absolutely positioned elements are determined by the next relative, fixed or absolutely positioned parent element. So if you have a div that’s positioned relative and 10px from the left, another element within that div that is positioned absolute and 10px from the left will be 20px from the left of the viewport.
    You have to give any parent element (probably the best would be the main container) position: relative; to have best control over how the absolutely positioned element will be positioned.

    Apart from that I’ll have to say that Myspace sucks (when it comes to modifying the code) and I’m not gonna waste my afternoon to look into your code and search for the correct element. Maybe someone else has the time and patience to do that.


    Posting Permissions

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