[PHP] Re: Variable Variables and Super Global Arrays

2008-10-11 Thread ANR Daemon
Greetings, "daniel danon". In reply to Your message dated Saturday, October 11, 2008, 2:50:34, > By php.net manual, "Please note that variable variables cannot be used with > PHP's Superglobal arrays within functions or class methods". Is there any > way to override this problem? Just the not nic

[PHP] Re: Variable variables

2006-01-24 Thread James Benson
Mark Steudel wrote: I was wondering if you could create variable variables for objects, please see examples below, Im having problems getting it to work. $data['fieldname'] = foo; // without variable variables $res =& $db->query( "SELECT foo FROM table" ); while( $res-

[PHP] Re: Variable variables

2004-08-28 Thread M. Sokolewicz
Janbro wrote: Hi List, I'm using PHP5 with global variables off. I've got around 20 dynamically generated forms with a total of 300 different variables sent thru these forms. I'd like to use variable variables, but according to the manual this is not possible. Now comes my Questoin, how do I rec

[PHP] Re: Variable Variables and Mulitdimensional Arrays

2002-03-16 Thread Joe Webster
You seem to have three different ideas/questions... let me attempt to answer them: > Hi. I want to be able to access a key in a multidimensional array at some > depth "n" without knowing before runtime what the keys are. let's take a multidimensional array $x $x = array( "somevar", array

[PHP] Re: variable variables and eval

2001-08-13 Thread Richard Lynch
> i have come across a strange problem with variable variables. Basicly i'm > doing the following and its not working: > > $section = 'data["SITE"][0]["NAME"][0]'; > $pData = 'My Site.'; > ${sprintf('$%s', $section)}.=$pData; > > but it is not working. But if i do this: > > eval('$'.$section.'.="'