parse error

5 views
Skip to first unread message

evan...@gmail.com

unread,
Dec 21, 2007, 1:17:16 AM12/21/07
to phpPayPal
hi. i tried posting the code as is and calling it to see if it would
work before modifying it but i got an error message saying "Parse
error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or
T_FUNCTION or T_VAR or '}' " on the line after "class phpPayPal {".
any ideas why this might be?

Drew

unread,
Dec 21, 2007, 9:03:27 AM12/21/07
to phpPayPal
Hi,

Can you include a snippet of the code around the line "class phpPayPal
{"?

I copied and pasted the latest phpPayPal download to a PHP script and
was able to create and use the class ok.

Or if you can send me the whole thing and I'll try exactly what you're
doing on my server and see what's up.

Drew

unread,
Dec 26, 2007, 6:44:29 PM12/26/07
to phpPayPal
Any luck on this? Were you able to figure out what's wrong?

If you can post your specific problem and solution it might help
others in the future.

On Dec 21, 12:17 am, "evanm...@gmail.com" <evanm...@gmail.com> wrote:

evan...@gmail.com

unread,
Dec 26, 2007, 9:01:38 PM12/26/07
to phpPayPal
Hey Drew,

I didn't touch the code in that phpPayPal class. I just ran the php
file that calls it just to see what would happen and I got that
message.

Evan

evan...@gmail.com

unread,
Dec 26, 2007, 9:03:31 PM12/26/07
to phpPayPal
It says "Parse error: parse error, unexpected T_STRING, expecting
T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /html/phpPayPal.php on
line 31".

Line 31 is: public $Response;

Drew

unread,
Dec 26, 2007, 10:44:42 PM12/26/07
to phpPayPal
Hi Evan,

Hmm, can you tell me what version of PHP you're running?

You might try using "public class phpPayPal {" instead of just "class
phpPayPal {" at the beginning of the class. But that's just a guess.

-Drew
Reply all
Reply to author
Forward
0 new messages