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 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Mar 2005
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question help with alinment issues

    im making a website and currently has 2 javascript 'objects'(dont really know what to call them) on the front page, problem is that they are both to the left of the screen, one above the other. what i need is one to be in the center and the other to be over to the right but not all the way, id say about 100 pixels away from the right of the screen. any help is GREATLY appreciated

  • #2
    Senior Coder
    Join Date
    Apr 2003
    Location
    Canada
    Posts
    1,063
    Thanks
    2
    Thanked 0 Times in 0 Posts
    CSS is the best solution I think.
    Let's say your js objects are divs. You give them ids.
    One is 'objONE', the other is 'objTWO'

    Code:
    <head>
    <style type='text/css'>
    
    #objONE { margin: 0 auto; }
    #objTWO { position: absolute; right: 100px; }
    
    </style>
    </head>
    Or something similar. You should look into CSS. It's really good for positionning.
    Shawn


  •  

    Posting Permissions

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