四虎精品视频-四虎精品成人免费网站-四虎黄色网-四虎国产视频-国产免费91-国产蜜臀97一区二区三区

php download.php實(shí)現(xiàn)代碼 跳轉(zhuǎn)到下載文件(response.redirect)

跳轉(zhuǎn)核心代碼實(shí)現(xiàn)。
復(fù)制代碼 代碼如下:
if (isset($link))
                {
                    Header("HTTP/1.1 303 See Other");
                    Header("Location: $link");
                    exit;
                }



下面是國外的一篇文章說明。
Hey Chris:
On Wed, Jan 26, 2005 at 12:28:19PM -0500, csnyder wrote:
>
> <?php
> // process form
> ...
> // redirect to results page
> header( 'HTTP/1.1 303 See Other' );
> header( 'Location: result.html' );
> exit( 'Form submitted, <a href="result.html">continue</a>.' );
> ?>
Good point. But some feedback here. The optimail syntax is:
<?php
// process form
// ...
// redirect to results page
header('Status: 303 See Other' );
header('Location: http://www.jb51.NET/result.html');
?>
Here's why...
Using "Status:" in the header is better because the resulting headers from
Apache are more correct:
HTTP/1.1 303 See Other
instead of
HTTP/1.1 303
Additionally, one doesn't really know which version of HTTP is being used,
so why potentially cause problems by trying to guess.
The specs say location headers must have a complete URI in them, not just
the path.
Lastly, you don't want any output after the location header.
Later,
--Dan

php技術(shù)php download.php實(shí)現(xiàn)代碼 跳轉(zhuǎn)到下載文件(response.redirect),轉(zhuǎn)載需保留來源!

鄭重聲明:本文版權(quán)歸原作者所有,轉(zhuǎn)載文章僅為傳播更多信息之目的,如作者信息標(biāo)記有誤,請第一時間聯(lián)系我們修改或刪除,多謝。

主站蜘蛛池模板: 罗丽星克莱尔电影妄想症| 李婷芷| 男女的隐私视频播放| 忏悔三昧念3遍| 彭丹丹最惊艳的电影| 美丽分贝 电视剧| 稻草狗在线观看| 疯狂愚蠢的爱| 7妹| 雪山飞狐之塞北宝藏演员表| 高锰酸盐指数和cod的关系| 55天在北京| 端午节手抄报一年级| 黑势力| 架子姐姐| 唱这歌| 陈芷琰的搞笑日常| 吴亿晨| 拔萝卜歌谱| 菊花台在线电视剧免费观看| 黄梅戏龙女全剧播放| 地火电视剧演员表| 清白堂记| 郑楚一| 少女秩序| 小学道德与法治课程标准2023版| 刑讯女烈| 三年级片| 月亮电影| tina kay| 谷桃子| 太上老君说五斗金章受生经| 一闪一闪亮晶晶电影免费| 冰之下| 新一剪梅电视剧演员表| xxxxxxcom| yoshizawa akiho| 谭耀文演的电影| 张孝全| 洪熙官个人资料简介| 国家级期刊目录|