[thelist] building a dynamic variable in php

Tom Dell'Aringa pixelmech at yahoo.com
Mon Jan 13 11:47:00 CST 2003


Hello,

I'm building a 'mail to friend' list where I have 10 form fields
labeled 1 through 10. In my php that processes the page, I thought
instead of doing:

$mail1 = $_POST["1"];

I would instead run through a loop to do it:

for($i = 1; $i <= 10; $i++) {

then I would dynamically set each variable. This was what I tried:

$mail . i = $_POST[i];

but this of course did not work. There must be a good way to do this
I would think...

Tom

=====
var me = tom.pixelmech.webDeveloper();

http://www.pixelmech.com/
http://www.maccaws.com/
[Making A Commercial Case for Adopting Web Standards]

__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com



More information about the thelist mailing list