Unexpected > error
-
So, in the file leaguemanager/lib/ajax.php, you need to check if a roster is empty (around line 142):
$selected = ( $dataset->id == $team->roster['id'] ) ? ' selected="selected"' : '';
Needs to be:
if (!empty($team->roster)) { $selected = ( $dataset->id == $team->roster['id'] ) ? ' selected="selected"' : ''; }
Otherwise you get an “Unexpected <” error in javascript. Basically, need to test if roster is not empty. Otherwise php throws errors which get push back to the javascript via ajax and cause errors.
- The topic ‘Unexpected > error’ is closed to new replies.