chokk Posted January 18, 2011 Share Posted January 18, 2011 Why am I getting a T_FUNCTION exception whenever I declare properties before the construct method? Link to comment Share on other sites More sharing options...
Synook Posted January 18, 2011 Share Posted January 18, 2011 Can you show us your code? Link to comment Share on other sites More sharing options...
Ingolme Posted January 18, 2011 Share Posted January 18, 2011 You probably are missing a semi-colon ( ; ) at the end of your property statements. Link to comment Share on other sites More sharing options...
chokk Posted January 18, 2011 Author Share Posted January 18, 2011 The class extends beyond the scope of the window and works perfectly fine without the variables at the top.Here is the error I'm receiving:Parse error: parse error, expecting `T_FUNCTION' in C:\wamp\www\projects\blablabla\backend\engine.php on line 4 Link to comment Share on other sites More sharing options...
chokk Posted January 18, 2011 Author Share Posted January 18, 2011 Oh dear.. I forgot to add private, public or protected... >.< Link to comment Share on other sites More sharing options...
boen_robot Posted January 18, 2011 Share Posted January 18, 2011 For the record, "show us your code" means copy&paste-ing the full text contents of the PHP file, not making a screenshot out of it. Link to comment Share on other sites More sharing options...
chokk Posted January 18, 2011 Author Share Posted January 18, 2011 The code worked fine without the variables and colored syntax makes it easier to spot mistakes, imo Link to comment Share on other sites More sharing options...
Synook Posted January 18, 2011 Share Posted January 18, 2011 But it's so tiny... and we can't re-copy-and-paste it to test ourselves if necessary. And attachments take up much more space on the board. Link to comment Share on other sites More sharing options...
chokk Posted January 18, 2011 Author Share Posted January 18, 2011 That's the biggest format my laptop supports .. And the file isn't attached, it's linked from tinypic.. But I get your point, I just thought it would be easier for you to spot any mistakes with colored syntax Link to comment Share on other sites More sharing options...
justsomeguy Posted January 18, 2011 Share Posted January 18, 2011 It is, but we have our own editors we can paste the code into to highlight it if necessary. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.