If you have just started to learn PHP, there may be many functions need to study, today we will learn how to use the PHP Header (), more instructions, please refer to the PHP Chinese manual, the following is a detailed use of the header function
Decompress the zip file using php.
The code is as follows:
Class zip
{
Var $ datasec, $ ctrl_dir = array ();
Var $ eof_ctrl_dir = "\ x50 \ x4b \ x05 \ x06 \ x00 \ x00 \ x00 \ x00 ";
Var $ old_offset = 0; var $ dirs = Array (".");
Function get_List (
Header ("http/1.1 404 Not Found");
Copy CodeFor the ErrorDocument 404/404.php function in Apache configuration, the
Error_page 404/404.php;
Copy CodeChange into
Error_page 404
Regardless of how many headers the page has, it executes the last one, but conditionally, for example:
Header (' location:http://www.jb51.net ');
Header (' location:http://www.g.cn ');
Header (' location:http://www.baidu.com ');
This will jump to
Easy to use method:
Copy the Code code as follows:
$object = new Httpdownload ();$object->set_byfile ($file)%n#h#%;//server file name, including path$object->filename = $filename;//download Save as file name$object->download ();
3. Source
Super small PHP pony summary (friends who are convenient to find backdoors ). Author: spider, I also come to a super small PHP pony to copy the code as follows :? Phpheader (content-Type: texthtml; charsetgb2312); if (get_magic_quotes_gpc () foreach
Decompress the PHP zip file. Copy the code as follows: classzip {var $ datasec, $ ctrl_dirarray (); var $ eof_ctrl_dirx50x4bx05x06x00x00x00x00; var $ old_offset0; var $ dirsArray (.); funct
The code is as follows:
Class zip{Var $ datasec, $
Php remote file download class (supports resumable upload ). Easy to use: Copy the code as follows: $ objectnewhttpdownload (); $ object-set_byfile ($ file) % N # H # %; server file name, including Path $ object-filename $ filename; download another
Copy CodeThe code is as follows:
Class zip
{
var $datasec, $ctrl _dir = Array ();
var $eof _ctrl_dir = "\x50\x4b\x05\x06\x00\x00\x00\x00";
var $old _offset = 0; var $dirs = Array (".");
function get_list ($zip _name)
{
$zip = @fopen ($zip _name, '
Easy to use method:
Copy CodeThe code is as follows:
$object = new Httpdownload ();
$object->set_byfile ($file)%n#h#%;//server file name, including path
$object->filename = $filename;//download Save as file name
$object->download ();
3. Source
No matter how many headers the page has, it executes the last one, but it is conditional, for example:
Header (' location:http://www.jb51.net ');
Header (' location:http://www.g.cn ');
Header (' location:http://www.baidu.com ');
This will jump to
How do I remove a header line in a Word document
First, Word2013 (Word2010) header horizontal How to remove
1. Quick Steps
Double-click the header area to enter the edit header status → Select all contents in the header (Ctrl + A) → Click the
Using the PHPheader () function to implement the 404 error prompt function on the page, we have sorted out the detailed usage of the PHPheader () function and shared it with you. We need a lot of support. If you are just learning PHP, many functions
1. function: supports resumable download, compute the transfer rate, and control the transfer rate. easy to use:
The code is as follows:
$ Object = new httpdownload ();
$ Object-> set_byfile ($ file) % N # H # %; // server file name, including
PHP Header code. According to PHPBIBLE, the header can send the Status header, for example, header (Status: 404 NotFound );? The 404 error file cannot be found in the user's browser can be displayed. according to Mr. Peng Wuxing's "php bible", the
The following describes how to use the header function. No matter how many headers are on the page, the function executes the last one, but it is conditional. For example: header (Location: www.jb51.net); header (Location: www.g.cn); header
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.