My first post on this brilliant website asking for some help with my first complicated php script that basically connects to a mysql db, queries data from an sqltable and displays it on a website.
Today, I got this error :=on Line 258 of my code :
Parse error: syntax error, unexpected '' (T_ENCAPSED_AND_WHITESPACE), expecting identifier (T_STRING) or variable (T_VARIABLE) or number (T_NUM_STRING) in /home/path/public_html/advanced_bans.php on line 258
I could fix other syntax errors, but I'm not even sure if this one is actually a syntax error. Here's the code : Line 2 (line 258 in the entire code) has the error
1 foreach( $result as $row ) { #modified
2 echo "<tr id='<?php echo $row['name']; ?>'".( ( $start % 2 ) == 0 ? " bgcolor=\"#FFFFFF\"" : " bgcolor=\"#E5E5E5\"" ) .">\n";
3 echo "<td style=\"text-align:center\">";
4 //echo ( $count + 1 );
5 echo $start + 1;
6 echo ".";
7 echo "</td>\n";
8
9 echo "<td style=\"text-align:left\">";
10 echo " ";
11 echo htmlspecialchars( $row[ 'name' ] );
12 echo "</td>\n";
Thanks in advance.
Kind Regards, ZEDD