james909 Posted March 27, 2013 Share Posted March 27, 2013 what would be causing the parse error on this line: $title_image ="<img src= \"http://www.britishpolarengines.co.uk/assets/images/logo.jpg\" border=\"0\" lt=\".: BPE Demo :.\" title=\".: BPE Demo :.\" hspace=\"5\" vspace=\"2\">"; Quote Link to comment https://forums.phpfreaks.com/topic/276216-parse-error-syntax-error-unexpected-t_string/ Share on other sites More sharing options...
DaveyK Posted March 27, 2013 Share Posted March 27, 2013 Its actually not unlikely the source of the error is not on that line, but the previous one. Post more relevant code please, in code brackets (the "<>" in the menu). Quote Link to comment https://forums.phpfreaks.com/topic/276216-parse-error-syntax-error-unexpected-t_string/#findComment-1421381 Share on other sites More sharing options...
james909 Posted March 27, 2013 Author Share Posted March 27, 2013 thanks for the reply davey $error_font_color = "red"; $title_image ="<img src= \"http://www.britishpolarengines.co.uk/assets/images/logo.jpg\" border=\"0\" lt=\".: BPE Demo :.\" title=\".: BPE Demo :.\" hspace=\"5\" vspace=\"2\">"; the $title_image is the T_STRING error line that the browser is showing. $error_font_color is the previous line. Quote Link to comment https://forums.phpfreaks.com/topic/276216-parse-error-syntax-error-unexpected-t_string/#findComment-1421392 Share on other sites More sharing options...
DaveyK Posted March 27, 2013 Share Posted March 27, 2013 I just posted this code on localhost and I dont get any errors... $error_font_color = "red"; $title_image ="<img src= \"http://www.britishpolarengines.co.uk/assets/images/logo.jpg\" border=\"0\" lt=\".: BPE Demo :.\" title=\".: BPE Demo :.\" hspace=\"5\" vspace=\"2\">"; var_dump($error_font_color); var_dump($title_image); the result I get is: string(3) "red" string(150) "" are you sure about the error? care to post all the relevant code? Quote Link to comment https://forums.phpfreaks.com/topic/276216-parse-error-syntax-error-unexpected-t_string/#findComment-1421398 Share on other sites More sharing options...
xxclear Posted March 27, 2013 Share Posted March 27, 2013 does it say what it is expecting instead of T_STRING? Quote Link to comment https://forums.phpfreaks.com/topic/276216-parse-error-syntax-error-unexpected-t_string/#findComment-1421433 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.