Creating a variable variable name
I've read about variable variables and string concatenation and could use some advice on the best approach for an html form I'm working on.
When I generate the form I sometimes loop sections that repeat.
One such loop is like this:
Phone1 Description1
Phone2 Description2
Phone3 Description3
The table record actually has fields Phone1, Description1, Phone2, ...etc. and I equate them to $phone1, $description1, $phone2, etc.
What I tried to do was to use $i to control to loop and then echo:
value='$phone$i' or value '$description$i' in an <input> statement but that doesn't work.
Thanks
Tom
Subject
Written By
Posted
Creating a variable variable name
November 20, 2010 08:44PM
November 22, 2010 12:09AM
November 24, 2010 08:13AM
November 24, 2010 04:35PM
November 25, 2010 09:31AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.