PHP parsing error on Smarty assign
| From: | Eric Ocean | Date: | Wed, 30 Jun 2004 19:44:50 +0000 |
| Subject: | PHP parsing error on Smarty assign | ||
| Groups: | php.smarty.general | ||
| Request: | Send a blank email to php-smarty-general+get-11509@lists.php.net to get a copy of this message | ||
Hello list,
Any ideas on why the parsing error occurs? The actual file starts on column 4, so the "heredoc" string is
correct. The parenthesis are properly balanced, etc. I've tried placing the parethesis at the beginning of
line 27; it didn't help.
Perhaps someone could verify that this is broken for them, too.
(I realize that the outer array is currently redundant; I plan to have more than one array embedded in it.)
Thanks,
Eric Ocean
01 <?php
02 require('Smarty.class.php');
03
04 $smarty = new Smarty;... // other assignments
17 $smarty->assign("C_functions", array(
18
19 array( "defaultPortCallback" => array( "returnType" => "CFDataRef", 20 "params" => array( "CFMessagePortRef" => "local", 21 "SInt32" => "msgid", 22 "CFDataRef" => "data", 23 "void *" => "info" ), 24 "code" => <<<EOD 25 return NULL;26 EOD;
27 ) 28 )));...
50 $smarty->fetch('pretty_print_function.tpl');
51 ?>
php -f "/the/file/above.php"
Parse error: parse error, expecting `')'' in /the/file/above.php on line 27