Sending GET and POST simultaneously

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
alex.barylski
DevNet Evangelist
Posts: 6267
Joined: Tue Dec 21, 2004 5:00 pm
Location: Winnipeg

Sending GET and POST simultaneously

Post by alex.barylski »

I know it's not standard practice or anyting, but say I have a FORM which submits via POST but in it's action attribute I also specify a query string with variables set using GET...

I tried this iin both IE and firefox and it's seems to work, so long as you check $_POST & $_GET directly not $_REQUEST...

So I assume it's acceptable...but is it really?

Cheers :)
User avatar
Nathaniel
Forum Contributor
Posts: 396
Joined: Wed Aug 31, 2005 5:58 pm
Location: Arkansas, USA

Post by Nathaniel »

I don't see why it wouldn't be. It's a valid URL, so why would the browser care?
d3ad1ysp0rk
Forum Donator
Posts: 1661
Joined: Mon Oct 20, 2003 8:31 pm
Location: Maine, USA

Post by d3ad1ysp0rk »

Yeah, sometimes I use that on control panels where I'll have:
news.php?action=add
news.php?action=edit
news.php?action=delete

and I'll trasnfer all the other info via post.
Charles256
DevNet Resident
Posts: 1375
Joined: Fri Sep 16, 2005 9:06 pm

Post by Charles256 »

I almost exsclusively use a combo of get and post
User avatar
dibyendrah
Forum Contributor
Posts: 491
Joined: Wed Oct 19, 2005 5:14 am
Location: Nepal
Contact:

may I know how to do that

Post by dibyendrah »

May I know how to do both POST and GET simultaneously ?
Post Reply