zero-perfoliate
zero-perfoliate

Author Topic: GOTO doesnt work?  (Read 168 times)

Offline indrek

  • New PHP Members
  • Posts: 1
  • Karma: +0/-0
GOTO doesnt work?
« on: August 10, 2010, 04:55:30 AM »
Im running Apache2 with PHP Version 5.2.6-3ubuntu4.5.  Everything seems working, except 'GOTO' its so strange and I cant figure out what im doing wrong. I made very simple script with GOTO called test.php:
<?php
goto a;
echo 'Foo';
a:
echo 'Bar';
?>

and I get this error "Parse error: syntax error, unexpected T_STRING in /home/web/test.php on line 2"

Can anyone help me with this?

 

zero-perfoliate