Cosmetic question

Discussion in 'Co-op Advertising Network' started by adsrus, Feb 8, 2005.

  1. #1
    can anyone tell me how to get the ads to display centrally in a table row, no matter what I do they are always left justified, this is the sort of code I'm using

    <body>
    <div align="center">
    <table border="0" cellpadding="0" style="border-collapse: collapse" width="100%" id="table1">
    <!-- MSTableType="nolayout" -->
    <tr>
    <td>
    <p>
    <?php
    ini_set ("include_path", ini_get ("include_path") . ':../:../../:../../../:../../../../');
    include ('ad_network.php');
    echo $ad_network[0]; echo " | "; echo $ad_network[1]; echo " | "; echo $ad_network[2]; echo " | "; echo $ad_network[3]; echo " | "; echo $ad_network[4];
    ?>
    </p>
    </td>
    </tr>
    </table>
    </div>
    </body>
     
    adsrus, Feb 8, 2005 IP
  2. digitalpoint

    digitalpoint Overlord of no one Staff

    Messages:
    38,334
    Likes Received:
    2,613
    Best Answers:
    462
    Trophy Points:
    710
    Digital Goods:
    29
    #2
    You could add an align="center" to your <td> tag.
     
    digitalpoint, Feb 8, 2005 IP
  3. adsrus

    adsrus Peon

    Messages:
    6
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    thanks, that has fixed it on some pages, others are still left justified, I suspect it's a function of the css style sheet for the page
     
    adsrus, Feb 8, 2005 IP
  4. ProductivePC

    ProductivePC Peon

    Messages:
    362
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Try adding the bolded statement to your code. If it is CSS, this will overwrite it when it gets to that paragraph tag.

    <body>
    <div align="center">
    <table border="0" cellpadding="0" style="border-collapse: collapse" width="100%" id="table1">
    <!-- MSTableType="nolayout" -->
    <tr>
    <td>
    <p style="text-align:center;">
    <?php
    ini_set ("include_path", ini_get ("include_path") . ':../:../../:../../../:../../../../');
    include ('ad_network.php');
    echo $ad_network[0]; echo " | "; echo $ad_network[1]; echo " | "; echo $ad_network[2]; echo " | "; echo $ad_network[3]; echo " | "; echo $ad_network[4];
    ?>
    </p>
    </td>
    </tr>
    </table>
    </div>
    </body>
     
    ProductivePC, Feb 9, 2005 IP
  5. adsrus

    adsrus Peon

    Messages:
    6
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    hi Wayne, your tip has worked!, where everything failed

    thanks

    Ken
     
    adsrus, Feb 10, 2005 IP
  6. ProductivePC

    ProductivePC Peon

    Messages:
    362
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Your welcome Ken. The real thanks goes to the people in the forums that helped train me in CSS.
     
    ProductivePC, Feb 10, 2005 IP