[TYPO3] pass variables to funtion in php content element?
Ries van Twisk
typo3 at rvt.dds.nl
Fri Apr 7 18:33:41 CEST 2006
Why not:
<?php
$GLOBALS['a'] = 'one';
foo();
function foo () {
echo "a is {$GLOBALS['a']}";
}
?>
>Hello,
>
>We use PHP 4.3.9. 'register_globals = Off' is set in the php.ini. The
>following script works fine on the web outside of typo3. But in typo3,
>it just returns 'a is'. $GLOBALS[TSFE]->page['title'] works fine
>though. How should I pass $a to foo() then?
>
><?php
>$a = 'one';
>foo();
>
>function foo () {
>
>echo "a is $GLOBALS[a]";
>}
>
>?>
>
>Thanks in advance,
>
>Bing
>_______________________________________________
>TYPO3-english mailing list
>TYPO3-english at lists.netfielders.de
>http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
>
>
--
Ries van Twisk
Freelance Typo3 Developer
=== Private:
email: ries at vantwisk.nl
web: http://www.rvantwisk.nl/
skype: callto://r.vantwisk
=== Work:
email: ries at livetravelguides.com
web: http://www.livetravelguides.com
More information about the TYPO3-english
mailing list