Jump to content

Archived

This topic is now archived and is closed to further replies.

insky10

Getting data from a Post

Recommended Posts

Hello,

I would like to know if anyone could help me get data from an HTTP Post.
Lets say I have an incoming string of data like such:

Name="Wendy" Color="Blue" Address="333 west"

I want to capture that entire string and then write it to a file. I can write to a file
fine, I am having trouble capturing the entire string. I have used the $_Post and
$HTTP_POST_VARS with no luck, it seems that I can only capture the first part of the string:

ie:
$data = $HTTP_POST_VARS['Name'];
or
$data = $_POST['Name'];

would get this result: "Wendy" Color="Blue" Address="333 west"

I want to capture the whole string like this:
Name="Wendy" Color="Blue" Address="333 west"

If I could parse it before I write it to the file, that would be even better..but I will
take the whole string.

Any help would be appreciated.

thanks

Share this post


Link to post
Share on other sites
[code]
$name = $_POST['Name'];
$address = $_POST['Address'];
$color = $_POST['Color'];
[/code]

?

Share this post


Link to post
Share on other sites
are you looking for something like:
[code]$_SERVER['QUERY_STRING'][/code]

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.