Forums

PHP

This topic is locked

Insert Record & Form Post Variables

Posted 13 May 2002 12:54:25
1
has voted
13 May 2002 12:54:25 Andrew Dresner posted:
I'm a bit of a newbie with this, so perhaps I've made a stupid mistake, but when I use the Phakt insert record behaviour i don't seem to be able to retreive any of the form variables on the redirected page (using $HTTP_POST_VARS associative array)

Do these get lost during the phakt insert record processing?

Thanks for your help,

Andrew

Andrew Dresner

Replies

Replied 13 May 2002 17:24:16
13 May 2002 17:24:16 Julio Taylor replied:
just change the forms's method to GET instead of POST:

<form name="form1" method="get" action="<?php echo $MM_editAction?>">

then make sure that you request the variables in the second page and display the results like so:

<?php echo $HTTP_GET_VARS["you text here"]?>

-- J

P.S. i killed kenny
Replied 14 May 2002 10:26:46
14 May 2002 10:26:46 Andrew Dresner replied:
Thanks alot for your help (and the really quick response)

Andrew

Andrew Dresner
Replied 05 Jul 2006 21:23:14
05 Jul 2006 21:23:14 sup ert replied:
Hi.
Same problem. I tried changing to GET, but then it reloads itself, with the form fields in the address bar, and doesn't go to the second page.

Any ideas?

supert

Edited by - supert on 05 Jul 2006 21:35:30
Replied 06 Jul 2006 11:35:05
06 Jul 2006 11:35:05 Roddy Dairion replied:
First of all, GET is to be used mostly when you do a search. It can be used for insert but this would mean that, your address bar will have all the fields and value appearing in it. Just imagine having 15 fields for an insert form, and you using get to insert it. So use POST when you do an insert.
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
Hi.
Same problem. I tried changing to GET, but then it reloads itself, with the form fields in the address bar, and doesn't go to the second page.

Any ideas?
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Is you page suppose to redirect anywhere after insert? if yes then check the link and you code. And also check your insert script.
Replied 13 Jul 2006 18:28:04
13 Jul 2006 18:28:04 Oriyomi Shokunbi replied:
If you are not working on a search page I will advice you to use post.
if the problem persist lets know.
You can always work around it with simple codes

Urmy

Reply to this topic