HTTP Functions

Table of Contents

Коментарии

$HTTP_RAW_POST_DATA --

You'll usually access variables from forms sent via POST method by just accessing the associated PHP global variable.

However, if your POST data is not URI encoded (i.e., custom application that's not form-based) PHP won't parse the data into nice variables for you.  You will need to use $HTTP_RAW_POST_DATA to access the raw data directly. (This should return a copy of the data given to the PHP process on STDIN; note that you wan't be able to open STDIN and read it yourself because PHP already did so itself.)
2001-01-04 22:37:57
http://php5.kiev.ua/manual/ru/ref.http.html
The method given below may not sometimes work.
The following method has always worked with me:
just put the following 3 lines in your PHP code

?>
<body onload=setTimeout("location.href='$url'",$sec)>
<?PHP
-------?>

$sec is the time in second after which the browser would automatically go to the url. Set it to 0 if you do not want to give any time.
You can use this function on the events of various html/form objects (eg.-onclick for button).eg.
<input type=button value="Go to Php.net" onclick=setTimeout("location.href='php.net'",0)>
Use this to one step back
<input type="button" value="Back" onclick=history.go(-1)>
2004-04-21 06:55:41
http://php5.kiev.ua/manual/ru/ref.http.html
Автор:
Regarding what the guy before said.  We've experienced problems where certain firewalls have encrypted the HTTP_REFERER meaning that it doesnt always contain the place you've come from.

Better to track where the user has come from either in a form post or in the url.
2004-07-07 14:39:11
http://php5.kiev.ua/manual/ru/ref.http.html
Actually, if you want to redirect a user why let HTML or JavaScript do it? Simply do this:

header("Location: http://www.example.com/");
2005-11-30 09:57:03
http://php5.kiev.ua/manual/ru/ref.http.html

    Поддержать сайт на родительском проекте КГБ