CSS DIV container align multibrowser+unwanted margin

Reply

Join Date: Oct 2008
Posts: 1
Reputation: Apaxe is an unknown quantity at this point 
Solved Threads: 0
Apaxe Apaxe is offline Offline
Newbie Poster

CSS DIV container align multibrowser+unwanted margin

 
0
  #1
Oct 5th, 2008
Hi,
[/CODE]
I'm trying to make a website using divs and CSS and I'm having some problemss that I just can't solve

1.I'm using a container DIV, to center the content, and in SAFARI everything falls apart.
2.in IE7 the second orange bar is too far from the bottom of the grey ones and in FIREFOX is less seen but, as i care for grids, I would like to make a 5px margin as everywhere else.

A JPG of the renders can be seen here: http://www.andresousa.eu/browser_screen.jpg

CSS USED

HTML and CSS Syntax (Toggle Plain Text)
  1. div#container{
  2. margin-left: auto;
  3. margin-right: auto;
  4. position: relative;
  5. width: 600px;
  6. display:block;
  7. }
  8.  
  9. div#orange_bar {
  10. position: relative;
  11. width:600px;
  12. background-color: #D75600;
  13. height: 16px;
  14. margin-bottom: 0px;
  15. }
  16.  
  17. div#content_left {
  18. display:table;
  19. position: relative;
  20. background-color:#353535;
  21. width: 110px;
  22. height: 110px;
  23. margin-top: 5px;
  24.  
  25. }
  26.  
  27. div#content_right {
  28. display:table;
  29. float:right;
  30. position: relative;
  31. background-color:#353535;
  32. width: 485px;
  33. height: 110px;
  34. bottom: 110px;
  35. margin-left: 0px;
  36.  
  37. }
HTML
HTML and CSS Syntax (Toggle Plain Text)
  1. <div id="container">
  2.  
  3. <div id="orange_bar"> <p>PHOTOGRAPHY</p></div>
  4. <div id="content_left"></div>
  5. <div id="content_right"></div>
  6. <div id="content_left"></div>
  7. <div id="content_right"></div>
  8.  
  9. <div id="orange_bar"> <p>PHOTOGRAPHY</p></div>
  10. <div id="content_left"></div>
  11. <div id="content_right"></div>
  12.  
  13. <div id="orange_bar"> <p>PHOTOGRAPHY</p></div>
  14. <div id="orange_bar"> <p>PHOTOGRAPHY</p></div>
  15.  
  16. </div>
Thanks a lot, I hope you can help me fixing this as I don't really wanna use tables.
Best regards.
Last edited by Apaxe; Oct 5th, 2008 at 9:20 pm.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the HTML and CSS Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC