www.webdeveloper.com
Results 1 to 5 of 5

Thread: Safari Table Displays

  1. #1
    Join Date
    Feb 2008
    Posts
    8

    Safari Table Displays

    Using AJAX & php to randomly develop and return tables, and drop them into a <div> container ( http://www.thegreatmartinicompany.co...ace-value.html ). As appropriate FF and IE display the tables side by side, but Safari stacks them on top of each other. An example of the returned code is below. Any ideas why Safari would do such a thing?


    <table style="margin-left:auto; margin-right:auto"><tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    </table>
    <table style="margin-left:auto; margin-right:auto"><tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    </table>
    <table style="margin-left:auto; margin-right:auto"><tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    <tr><td></td></tr>
    </table>

  2. #2
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    21,654
    Remove
    Code:
    <table style="margin-left:auto; margin-right:auto">
    Add
    Code:
    <table cellpadding="0" cellspacing="0">
    and
    Code:
    table {float:left; margin:20px 10px 0 0;}
    At least 98% of internet users' DNA is identical to that of chimpanzees

  3. #3
    Join Date
    Feb 2008
    Posts
    8
    Fang,

    There can be anywhere between one and seven single column tables randomly returned that will be placed in the <div> element. I want them to be centered and symmetrically distributed within the container, which I believe will be lost in FF if I remove the auto margins.

  4. #4
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    21,654
    Code:
    table {display:inline-block; margin:auto;}
    At least 98% of internet users' DNA is identical to that of chimpanzees

  5. #5
    Join Date
    Feb 2008
    Posts
    8
    That fixed it! Thanks Fang,

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles