Forum Moderators: coopster
Check the lines immediately prior to 241. Look for missing semi-colon, a variable name not properly quoted, etc. There is nothing wrong with the code that you posted.
If all else fails, add this line to the top of your script and work your way thru the errors.
error_reporting(E_ALL);