Parse error: parse error, unexpected T_LNUMBER in /hsphere/local/home/addy4488/visiteureka.net/episodes.html on line 165
Line 165 is highlighted.
if ( (@$s) && (@$e) )
{
print "<table border='0' width='600' cellspacing='0' cellpadding='0'>";
print "<tr>";
print "<td align='center' valign='top'>";
if (@$s)
{
$sql = mysql_query("SELECT season FROM episodes WHERE tvshow = '$tvshow' AND season = '$s' ORDER BY season,episode");
$sql1 = mysql_query("SELECT id FROM episodes WHERE tvshow = '$tvshow' AND season = '$s' ORDER BY season,episode");
$sql2 = mysql_query("SELECT episode FROM episodes WHERE tvshow = '$tvshow' AND season = '$s' ORDER BY season,episode");
$sql3 = mysql_query("SELECT title FROM episodes WHERE tvshow = '$tvshow' AND season = '$s' ORDER BY season,episode");
$rows = mysql_num_rows($sql);
$row = $rows/3;
$row1 = $row+$row;
$i=0;
while($i<$row)
{
$season=mysql_result($sql,$i);
$id=mysql_result($sql1,$i);
$episode=mysql_result($sql2,$i);
$title=mysql_result($sql3,$i);
print "<a href='episodes.html?s=$seasons&e=$id' title='View This Episode'><span class='title3'>$season$episode - $title<br></span></a>";
$i++;
}
}
Please Help!
Started by ian mullen, Dec 02 2006 09:14 AM
1 reply to this topic
#1
Posted 02 December 2006 - 09:14 AM
#2
Posted 02 December 2006 - 10:35 AM
Can't really see the problem myself, must be before that.
But why are you querying 4 seperate times?
Here's a reduced version (also makes more sense).
I'm not sure why you're getting that problem, check your quotes earlier in the script, most probably it isn't properly closed or something, only reason I can think of.
But why are you querying 4 seperate times?
Here's a reduced version (also makes more sense).
if($s && $e){
echo "<table border='0' width='600' cellspacing='0' cellpadding='0'>\n<tr>\n<td align='center' valign='top'>";
if($s){
$sql = mysql_query("SELECT `season`, `id`, `episode`, `title` FROM `episodes` WHERE `tvshow` = '$tvshow' AND season = '$s' ORDER BY `season`,`episode`");
$rows = mysql_num_rows($sql);
$row = $rows/3;
$row1 = $row+$row;
while($row = mysql_fetch_assoc($sql)){
echo "<a href='episodes.html?s={$row['seasons']}&e={$row['id']}' title='View This Episode'><span class='title3'>{$row['season']}{$row['episode']} - {$row['title']}<br></span></a>";
}
}
Unless I missed the point of the whole dividing the result count by three, not sure what thats for.I'm not sure why you're getting that problem, check your quotes earlier in the script, most probably it isn't properly closed or something, only reason I can think of.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
