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
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]
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.