...

View Full Version : php://input example



jjshell
06-19-2005, 10:36 AM
hello,
could someone show an example of how to use the php://input wrapper? couldn't find one in the manual.

any help would be greatly appreciated.

:)

Nightfire
06-19-2005, 10:51 AM
http://uk2.php.net/wrappers.php

That any help?

jjshell
06-21-2005, 10:16 AM
hi, thanks for your reply :)
unfortunately, this page is at the origin of my question... so unfortunately it doesn't help, but thanks anyway :)

Can something like this be done?


$roughHTTPPOST = php://input;


I hope you know what I'm trying to do now.

:)

Nightfire
06-21-2005, 12:07 PM
Yeah, had a look at the page myself and couldn't really see any examples. Can't even find any on google and I've never used it before, so unfortunately can't help you :(

delinear
06-21-2005, 01:54 PM
You can use it the same way as it shows on that page for php://filter, in other words:

$roughHTTPPOST = readfile("php://input");
That works for me, anyway. Try this little script to see if it works for you:

<?php
if(!isset($_POST) || empty($_POST)) {
?>
<form name="form1" method="post" action="">
<input type="text" name="textfield"><br />
<input type="submit" name="Submit" value="Submit">
</form>
<?php
} else {
$roughHTTPPOST = readfile("php://input");
echo $roughHTTPPOST;
}
?>

jjshell
06-26-2005, 04:09 PM
thank you very much :)
worked great :)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum