[PHP-DEV] Language Question

2001-02-14 Thread John Woolbright
Is there any way in php to create macros for inline execution of code without creating scoping issues like function() does. For Example: if you had a macro set up so like this Macro($x) { for($i=0;$i$x;$i++) { echo $x; } } and a program like this $x=15; Macro($x); $x=45

Re: [PHP-DEV] Language Question

2001-02-14 Thread Cynic
just replace $var with $GLOBALS['var'] where you want a global no matter what. However, I would also welcome macros. At 18:16 14.2. 2001, John Woolbright wrote the following: -- Is there any way in php to create macros for inline