Jump to content

different text positions in same <td></td>


cameeob2003

Recommended Posts

I am trying to run the following code:

[code]<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td background="images/news_'. $table_background .'.jpg" height="19" align="left" valign="bottom" align="center"><font style="font-family:Arial, Helvetica, sans-serif; font-size:12px; color:#CCCCCC"/>'. $title .' '. $date .'</td>
</tr>
<tr>
<td align="left" background="images/news_2.jpg"><font style="font-family:Arial, Helvetica, sans-serif; font-size:12px; color:#000000"/>'. $content .'</td>
</tr>
<tr>
<td><img src="images/news_'. $td_background .'.jpg" width="652" height="17" alt=""></td>
</tr>
</table>[/code]
As you can see I want the "  '. $title.'  " and the  "  '.$date.'  " to be seperated on oposite sides of the <td> span but im not sure how to acomplish this. Any help is appreciated.
Link to comment
https://forums.phpfreaks.com/topic/16233-different-text-positions-in-same/
Share on other sites

You'll have to squeeze in a table inside the <TD></TD> tags and make sure you set the width of the table to 100%

[code]<td background="images/news_'. $table_background .'.jpg" height="19" align="left" valign="bottom" align="center">

<table style="width:100%;font-family:Arial, Helvetica, sans-serif; font-size:12px; color:#CCCCCC">
<tr>
<td>'. $title .'</td>
<td align="right"> '. $date .'</td>
</tr>
</table>

</td>[/code]

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.