Re: [PHP] Variable variables and references

2007-03-14 Thread Robert Cummings
On Wed, 2007-03-14 at 12:39 +0100, Jochem Maas wrote: > Richard Lynch wrote: > > On Sat, March 10, 2007 6:28 am, Dave Goodchild wrote: > >> Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I > >> think > >> it's a great book, I am confused about variable variables and > >> refere

Re: [PHP] Variable variables and references

2007-03-14 Thread Jochem Maas
Richard Lynch wrote: > On Sat, March 10, 2007 6:28 am, Dave Goodchild wrote: >> Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I >> think >> it's a great book, I am confused about variable variables and >> references - >> not the mechanics, just where you would use them. >> >>

Re: [PHP] Variable variables and references

2007-03-12 Thread Richard Lynch
On Sat, March 10, 2007 6:28 am, Dave Goodchild wrote: > Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I > think > it's a great book, I am confused about variable variables and > references - > not the mechanics, just where you would use them. > > The subject of variable variab

Re: [PHP] Variable variables and references

2007-03-11 Thread Martin Alterisio
2007/3/10, Dave Goodchild <[EMAIL PROTECTED]>: Hi guys, I have just read 'Programming PHP' (O'Reilly) and although I think it's a great book, I am confused about variable variables and references - not the mechanics, just where you would use them. The subject of variable variables is explained

Re: [PHP] Variable variables and references

2007-03-10 Thread M.Sokolewicz
I'd agree with Tijnema! here, variable variables aren't really of any use here. However, a classic snippet of code is where one emulates register_globals functionality in a non-register_globals environment (not a good idea to do this btw, unless you know what you're doing and don't have any oth

Re: [PHP] Variable variables and references

2007-03-10 Thread Tijnema !
On 3/10/07, Matt Carlson <[EMAIL PROTECTED]> wrote: I've used variable variables probably 5 times in 2 years. They are great when you need them, but don't usually have a day-to-day use for them. Here is some sample code of the last time I used it. if(isset($$key)) {

Re: [PHP] Variable variables and references

2007-03-10 Thread Matt Carlson
I've used variable variables probably 5 times in 2 years. They are great when you need them, but don't usually have a day-to-day use for them. Here is some sample code of the last time I used it. if(isset($$key)) { print($$key); continue;

Re: [PHP] Variable variables and references

2007-03-10 Thread Tijnema !
I must say, in all the years i am programming with PHP (about 5-6 years) i NEVER used references. So i don't find it useful, but well, if you want to give your variable content more than one name, you can :) I think you just need to start programming now, keeping in mind they are available, but d