|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2006-09-08 14:57 UTC] alan at 1st-straw dot com
Description:
------------
I'm in the process of converting VBA code into PHP (lots of fun). In the process of debugging a class and I'm get the following error:
Parse error: parse error, unexpected T_VARIABLE in F:\mailing list\1ststrawCMS\mysql\scripts\CContact.inc on line 1187
I comment out the offeding lines and still get the error. I have tried //, /* */ and # and still get the error.
I have included the offending lines below. Let me know if more informantion is needed.
Reproduce code:
---------------
If ($this->prefix != $v->Getprefix()) :
If (strlen($strSQL1) > 0) :
$strSQL1 += ", ";
else:
$strSQL1 = "SET ";
endif;
If ($v->Getprefix() = "") :
$strSQL1 += "prefix = null";
/* else: THIS IS LINE 1186
$strSQL1 += "prefix = '$v->Getprefix()'"; */
endif;
endif;
BLAH
Expected result:
----------------
Parse error: parse error, unexpected T_VARIABLE in F:\mailing list\1ststrawCMS\mysql\scripts\CContact.inc on line 1190
Actual result:
--------------
Parse error: parse error, unexpected T_VARIABLE in F:\mailing list\1ststrawCMS\mysql\scripts\CContact.inc on line 1187
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 09:00:01 2025 UTC |
Can't reproduce. Your code works just fine here. Also I'd recommend using readable syntax with { } for code blocks instead of blindly copying VB syntax.