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 don't use them if it isn't needed.

Tijnema


On 3/10/07, Dave Goodchild <[EMAIL PROTECTED]> 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 variables is explained but no examples are given
as
to why and where you would utilise them.

As for references, the examples given with regard to passing and returning
by reference in functions is clear, but no real examples are given as to
when this would be a preferred approcah - in fact, the authors stress that
due to PHP's copy-on-write mechanism, it is not a frequently-used
approcah.

So my question - are there any 'classic' situations in which either should
be used, and where and when do you guys use them in your real-world
efforts?
--
http://www.web-buddha.co.uk

Reply via email to