Re: formatting problems:
| From: | Ryan A | Date: | Tue, 16 Aug 2005 23:19:37 +0000 |
| Subject: | Re: formatting problems: | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-220724@lists.php.net to get a copy of this message | ||
On 8/16/2005 9:59:30 PM, Scott Noyes (snoyes@gmail.com) wrote:
> It's not clear to me how strict you want to be regarding the
> formatting. Are you trying to keep scenes together on each line, or
> just dump everything and let it wrap where it needs to? Perhaps you
> could handcode a sample and post a link. I'd
> also guess that you
> could make good use of CSS, specifically the "float: left" and
> clear=all attributes.
Hey,
Thanks for replying.
basically I want this part to keep looping:
<tr>
<td> </td>
<td> </td>
<td> </td>
</tr>
(Below I am attaching the whole code again so you can see)
To see the format I am after click here:
www.ezee.se/format.htm
Thanks,
Ryan
<?php
$hostt="localhost";
$userr="";
$passs="";
$db="movies";
$connected=mysql_connect("$hostt", "$userr", "$passs") or die ('I
cannot
connect to the database because: ' . mysql_error());
mysql_select_db ("$db");
$q=mysql_query("select * from csv_28814");
$num_rows = mysql_num_rows($q);
$flick_name2="";
$once=0;
for($i=0; $i < $num_rows; $i++)
{
$row = mysql_fetch_row($q);
$flick_name = $row[0];
$part_url = $row[1];
$part_size = $row[2];
$time_length = $row[3];
$part_format = $row[4];
if($flick_name != $flick_name2)
{
echo "<table width='80%' bgcolor=gray border='0'
cellspacing='0'
cellpadding='0'>
<tr>
<td colspan='2'><strong><font
size='+1'>Title</font></strong></td>
<td width='40%'> </td>
</tr>
<tr>
<td width='22%' align='center' valign='middle'>cover pic
</td>
<td colspan='2' nowrap><table width='100%' border='0'
cellspacing='0'
cellpadding='0'>
<tr>
<td width='81%'><strong>Scenes</strong></td>
<td width='10%'><strong>Length</strong></td>
<td width='9%'><strong>Format</strong></td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table></td>
</tr>
</table><br>\n\n\n\n\n\n\n\n\n";
}
$flick_name2 = $flick_name;
}
?>