国产片侵犯亲女视频播放_亚洲精品二区_在线免费国产视频_欧美精品一区二区三区在线_少妇久久久_在线观看av不卡

服務器之家:專注于服務器技術及軟件下載分享
分類導航

PHP教程|ASP.NET教程|Java教程|ASP教程|編程技術|正則表達式|C/C++|IOS|C#|Swift|Android|VB|R語言|JavaScript|易語言|vb.net|

服務器之家 - 編程語言 - PHP教程 - php header函數的常用http頭設置

php header函數的常用http頭設置

2020-10-06 18:01PHP教程網 PHP教程

這篇文章主要介紹了php header函數的常用http頭設置,本文直接給出代碼實例,代碼中包含詳細注釋,需要的朋友可以參考下

?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//ok
header(‘HTTP/1.1 200 OK');
//設置一個404頭:
header(‘HTTP/1.1 404 Not Found');
//設置地址被永久的重定向
header(‘HTTP/1.1 301 Moved Permanently');
//轉到一個新地址
header(‘Location: http://www.example.org/‘);
//文件延遲轉向:
header(‘Refresh: 10; url=http://www.example.org/‘);
print ‘You will be redirected in 10 seconds';
//當然,也可以使用html語法實現
// <meta http-equiv=”refresh” content=”10;http://www.example.org/ />
// override X-Powered-By: PHP:
header(‘X-Powered-By: PHP/4.4.0′);
header(‘X-Powered-By: Brain/0.6b');
//文檔語言
header(‘Content-language: en');
//告訴瀏覽器最后一次修改時間
$time = time() – 60; // or filemtime($fn), etc
header(‘Last-Modified: ‘.gmdate(‘D, d M Y H:i:s', $time).' GMT');
//告訴瀏覽器文檔內容沒有發生改變
header(‘HTTP/1.1 304 Not Modified');
//設置內容長度
header(‘Content-Length: 1234′);
//設置為一個下載類型
header(‘Content-Type: application/octet-stream');
header(‘Content-Disposition: attachment; filename=”example.zip”‘);
header(‘Content-Transfer-Encoding: binary');
// load the file to send:
readfile(‘example.zip');
// 對當前文檔禁用緩存
header(‘Cache-Control: no-cache, no-store, max-age=0, must-revalidate');
header(‘Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past
header(‘Pragma: no-cache');
//設置內容類型:
header(‘Content-Type: text/html; charset=iso-8859-1′);
header(‘Content-Type: text/html; charset=utf-8′);
header(‘Content-Type: text/plain'); //純文本格式
header(‘Content-Type: image/jpeg'); //JPG***
header(‘Content-Type: application/zip'); // ZIP文件
header(‘Content-Type: application/pdf'); // PDF文件
header(‘Content-Type: audio/mpeg'); // 音頻文件
header(‘Content-Type: application/x-shockw**e-flash'); //Flash動畫
//顯示登陸對話框
header(‘HTTP/1.1 401 Unauthorized');
header(‘WWW-Authenticate: Basic realm=”Top Secret”‘);
print ‘Text that will be displayed if the user hits cancel or ‘;
print ‘enters wrong login data';

延伸 · 閱讀

精彩推薦
Weibo Article 1 Weibo Article 2 Weibo Article 3 Weibo Article 4 Weibo Article 5 Weibo Article 6 Weibo Article 7 Weibo Article 8 Weibo Article 9 Weibo Article 10 Weibo Article 11 Weibo Article 12 Weibo Article 13 Weibo Article 14 Weibo Article 15 Weibo Article 16 Weibo Article 17 Weibo Article 18 Weibo Article 19 Weibo Article 20 Weibo Article 21 Weibo Article 22 Weibo Article 23 Weibo Article 24 Weibo Article 25 Weibo Article 26 Weibo Article 27 Weibo Article 28 Weibo Article 29 Weibo Article 30 Weibo Article 31 Weibo Article 32 Weibo Article 33 Weibo Article 34 Weibo Article 35 Weibo Article 36 Weibo Article 37 Weibo Article 38 Weibo Article 39 Weibo Article 40
主站蜘蛛池模板: 日韩成人在线播放 | 亚洲精品欧美 | 国产中文字幕在线播放 | 亚洲一区二区免费视频 | 日韩成人在线播放 | 成人一区二区三区在线观看 | 成人伊人| 在线观看毛片网站 | 日韩精品久久久 | 精品久久久久国产 | 超碰毛片 | 欧美日韩综合精品 | 一级片在线观看 | 日韩av在线中文字幕 | 欧美婷婷 | 亚洲成人av在线 | 99精品在线| 亚洲精品欧美 | 欧美亚洲国产日韩 | 久久综合成人精品亚洲另类欧美 | 久久久91精品国产一区二区三区 | 久久影音先锋 | 午夜视频国产 | 日本黄色一级 | 亚洲激情视频 | 深夜影院深a| 成人不卡视频 | 成人片在线播放 | 91在线看片| 欧洲国产一区 | 天天操天天添 | 久久xx | 日韩福利视频导航 | 欧美一区二区三区在线观看视频 | 亚洲色图88 | theporn国产在线精品 | 欧美国产综合 | 欧美激情精品久久久久久 | 国产精品一区二区三区在线播放 | 日韩在线精品视频 | 国产福利视频 |