For Programmers: Free Programming Magazines  


Home > Archive > PHP Programming > April 2004 > List of all $_POST variables transmitted ?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author List of all $_POST variables transmitted ?
Arnaud

2004-04-29, 5:14 pm

Hi,
Does Php can give us a way to find the name of all the POST variables
transmitted between two pages ?
I'm looking for a similar way to access those variables names than with
javascript and his document.forms["myform"].elements[0], something like
that...

Actually in my first form i have some dynamic names, and it's quite
difficult to exploit later, in form 2, when you have to rebuild them, i have
to use eval(), that's not so easy, so i'm looking for a smarter/easier way
to do it.

Any ideas ?
Thanks,
Arnaud


Jan Pieter Kunst

2004-04-29, 5:14 pm

In article <40912d2f$0$17520$626a14ce@news.free.fr>, "Arnaud" <b>
wrote:

> Does Php can give us a way to find the name of all the POST variables
> transmitted between two pages ?


array_keys($_POST) ?

JP

--
Sorry, <devnull@cauce.org> is een "spam trap".
E-mail adres is <jpk"at"akamail.com>, waarbij "at" = @.
Chris Hope

2004-04-29, 5:14 pm

"Arnaud" <b> wrote:

> Hi,
> Does Php can give us a way to find the name of all the POST variables
> transmitted between two pages ?
> I'm looking for a similar way to access those variables names than with
> javascript and his document.forms["myform"].elements[0], something like
> that...
>
> Actually in my first form i have some dynamic names, and it's quite
> difficult to exploit later, in form 2, when you have to rebuild them, i
> have to use eval(), that's not so easy, so i'm looking for a
> smarter/easier way to do it.


This will give you both the names and values.

print_r($_POST);

--
Chris Hope
The Electric Toolbox - http://www.electrictoolbox.com/
Arnaud

2004-04-30, 9:17 am

"Chris Hope" <chris@electrictoolbox.com> a écrit dans le message de
news:1083265055_12075@news.athenanews.com...
> This will give you both the names and values.
> print_r($_POST);


Thanks Chris and JP, that's exactly what i needed.

bye
Arnaud


Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2010 codecomments.com