Mindphp.com เว็บ สอนสร้างเว็บไซต์ ฐานข้อมูล php Javascript Ajax Jquery Html CSS CMS CRM และ เว็บเซอเวอร์ Hosting Web Server สอน Joomla phpbb JpGraph
Home บทความ เทคนิค การเขียน PHP Header HTTP Status Codes that the Web Server can return - Definitions

Header HTTP Status Codes that the Web Server can return - Definitions

เทคนิค การเขียน PHP

Header รายงานสถานะต่างๆ ของ web server ที่ตอบสนองต่อ Browser หรือ โปรแกรมที่ร้องขอไป ยัง Web Serve กำหนดไว้ดังนี้  200 คือ ปกติ ส่วนอื่นๆ คือการมีปัญหา และสาเหตุ ลองอ่านดูครับ

Header HTTP Status Codes that the Web Server can return - Definitions

  1. 200 OK
  2. 301 Moved Permanently
  3. 302 Found
  4. 304 Not Modified
  5. 307 Temporary Redirect
  6. 400 Bad Request
  7. 401 Unauthorized
  8. 403 Forbidden
  9. 404 Not Found
  10. 410 Gone
  11. 500 Internal Server Error
  12. 501 Not Implemented

HTTP Status Code - 301 Moved Permanently

The requested resource has been assigned a new permanent URI and any future references to this resource SHOULD use one of the returned URIs.

Test URI: /w3c/status-codes/301.asp

Back to Previous

HTTP Status Code - 302 Found

The requested resource resides temporarily under a different URI. Since the redirection might be altered on occasion, the client SHOULD continue to use the Request-URI for future requests.

Test URI: /w3c/status-codes/302.asp

Admin Note: 2005-03-14 - During the past several months, many discussions have been taking place in the search engine marketing communities concerning what many refer to as pagejacking. What you are about to read concerns everyone who has a website online, this is not an isolated incident. Those who are involved with the page jacking issues may not even know that they are causing harm to those they are linking to using a 302 Found redirect. Many of the 302s are generated from exit tracking scripts.

Back to Previous

HTTP Status Code - 304 Not Modified

If the client has performed a conditional GET request and access is allowed, but the document has not been modified, the server SHOULD respond with this status code. The 304 response MUST NOT contain a message-body, and thus is always terminated by the first empty line after the header fields.

Back to Previous

HTTP Status Code - 307 Temporary Redirect

The requested resource resides temporarily under a different URI. Since the redirection MAY be altered on occasion, the client SHOULD continue to use the Request-URI for future requests. This response is only cacheable if indicated by a Cache-Control or Expires header field.

Test URI: /w3c/status-codes/307.asp

Back to Previous

HTTP Status Code - 400 Bad Request

The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications.

Back to Previous

HTTP Status Code - 401 Unauthorized

The request requires user authentication. The response MUST include a WWW-Authenticate header field containing a challenge applicable to the requested resource.

Back to Previous

HTTP Status Code - 403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request SHOULD NOT be repeated.

Back to Previous

HTTP Status Code - 404 Not Found

The server has not found anything matching the Request-URI. No indication is given of whether the condition is temporary or permanent.

Test URI: /w3c/status-codes/404.asp

Back to Previous

HTTP Status Code - 410 Gone

The requested resource is no longer available at the server and no forwarding address is known. This condition is expected to be considered permanent. Clients with link editing capabilities SHOULD delete references to the Request-URI after user approval.

If the server does not know, or has no facility to determine, whether or not the condition is permanent, the status code 404 Not Found SHOULD be used instead. This response is cacheable unless indicated otherwise.

Test URI: /w3c/status-codes/410.asp

Back to Previous

HTTP Status Code - 500 Internal Server Error

The server encountered an unexpected condition which prevented it from fulfilling the request.

Back to Previous

Header HTTP Status Code - 501 Not Implemented

The server does not support the functionality required to fulfill the request. This is the appropriate response when the server does not recognize the request method and is not capable of supporting it for any resource.

Back to Previous


ใครว่างๆ ช่วยแปลหน่อยครับ

User Rating: / 1
แย่ดีที่สุด 

หน้าเว็บบอร์ด Programming - PHP ตั้งกระทู้ใหม่ ใน Programming - PHP, phpBB3, SMF, Joomla, Wordpress, CMS CRM ตั้งกระทู้ใหม่ ใน phpBB3, SMF, Joomla, Wordpress, CMS CRM, JavaScript & Jquery Ajax ตั้งกระทู้ใหม่ ใน JavaScript & Jquery Ajax, SQL - Database ตั้งกระทู้ใหม่ ใน SQL - Database, ถาม - ตอบ คอมพิวเตอร์ ตั้งกระทู้ใหม่ ใน ถาม - ตอบ คอมพิวเตอร์, PHP Knowledge ตั้งกระทู้ใหม่ ใน PHP Knowledge, PHP News ตั้งกระทู้ใหม่ ใน PHP News, HTML CSS ตั้งกระทู้ใหม่ ใน HTML CSS, Free PHP Code Download script ตั้งกระทู้ใหม่ ใน Free PHP Code Download script, Web Hosting Review - Free Host Share Host VPS ตั้งกระทู้ใหม่ ใน Web Hosting Review - Free Host Share Host VPS
หัวข้อกระทู้ ตอบ เปิดดู โดย
รบกวนสอบถามการรับค่าจาก textfile
โดย butterney 2012/05/15 19:16 บอร์ด Programming - PHP
6 120 2012/05/16 20:41
โดย butterney
มีปัญหาอ้ะครับ มาช่วยหน่อยนะครับ
โดย namkabz 2012/05/17 01:19 บอร์ด Programming - PHP
0 34 2012/05/16 18:19
โดย namkabz
สอบถาม เรื่อง "การสร้างดาต้าเบสสำหรับ Backup ครับ"
โดย Chayyim 2012/05/16 23:05 บอร์ด SQL - Database
0 41 2012/05/16 16:05
โดย Chayyim
ช่วยหน่อยคัฟ ไม่เก่ง PHP แต่พึ่งเริ่มทำงาน ติดปัญหาซะแร้ววว
โดย M&N 2012/05/04 16:03 บอร์ด Programming - PHP
3 431 2012/05/16 15:54
โดย tohkai_php
HTML5 สำหรับ Yii Framework
โดย mindphp 2012/04/17 09:32 บอร์ด PHP Knowledge
1 296 2012/05/16 15:50
โดย tohkai_php
รับสมัครพนังงานต่ำแหน่ง it support ครับ
โดย tohkai_php 2012/05/16 22:44 บอร์ด PHP News
0 46 2012/05/16 15:44
โดย tohkai_php
html5 + javascript เสมือน apps mobile เนียนมากๆครับ
โดย tohkai_php 2012/05/16 22:43 บอร์ด Free PHP Code Download script
0 45 2012/05/16 15:43
โดย tohkai_php
รบกวนขอความรู้ครับ
โดย Sum76 2009/02/06 20:13 บอร์ด Programming - PHP
3 398 2012/05/16 10:50
โดย malangtub
ขั้นตอนการทำงาน ระหว่าง Client - เว็บไซต์เรา และ facebook
โดย mindphp 2011/12/13 08:08 บอร์ด Programming - PHP
1 582 2012/05/16 10:45
โดย malangtub
ใช้ php สร้าง WebServices ด้วย PHPSoap
โดย batman1292 2012/05/08 03:02 บอร์ด PHP Knowledge
5 666 2012/05/16 10:35
โดย malangtub
ถามเกี่ยวกับสคริป php หน่อยคับ โทษทีถ้าถามผิดห้อง
โดย youscoms 2012/04/24 01:49 บอร์ด Programming - PHP
4 623 2012/05/16 10:24
โดย บุคคลทั่วไป
ปัญหาการติดตั้ง magento Database connection error.
โดย docman 2012/04/24 21:13 บอร์ด Programming - PHP
2 336 2012/05/16 10:22
โดย malangtub
php มีคำสั่ง block แถบเมนูไหมค่ะ
โดย NatoOne 2012/04/21 23:01 บอร์ด Programming - PHP
6 590 2012/05/16 10:21
โดย malangtub
Count down Javascript โปรเจ็คเกี่ยวกับการทำข้อสอบ
โดย ultraman_neww 2012/05/06 02:50 บอร์ด Programming - PHP
4 453 2012/05/16 10:16
โดย malangtub
ถามเกี่ยวกับหน้า login และ timestamp หน่อยครับ
โดย OneLifeBegin 2012/04/24 18:25 บอร์ด Programming - PHP
13 1611 2012/05/16 08:41
โดย ekaja
ที่ตั้งการ upload
โดย Pleumiie 2012/04/24 23:08 บอร์ด Programming - PHP
6 391 2012/05/16 08:30
โดย ekaja
เพิ่มพลังในการทำงานด้วยสิ่งนี้ดีกว่า อิอิ
โดย oliveen 2012/05/15 23:24 บอร์ด โหลดโปรแกรม พูดคุยเรื่องทั่วไป จับฉ่าย
1 242 2012/05/15 16:24
โดย starseed
มีปัญหาตารางของฐานข้อมูลมันแสดงขึ้นมาว่า "in use" ครับ
โดย Nakorn1911 2012/05/15 01:53 บอร์ด SQL - Database
3 154 2012/05/15 13:33
โดย Nakorn1911

New Members

sirintra : 16/05/2012 ปาริชาติ รัชฎาศรี : 16/05/2012 margarin : 16/05/2012 Chayyim : 16/05/2012 masteriii : 16/05/2012 ekaja : 16/05/2012 starseed : 15/05/2012 chanthasone : 15/05/2012 butterney : 15/05/2012 True_net : 15/05/2012 bethezank : 15/05/2012 potae2424 : 15/05/2012 theoldza123 : 14/05/2012 nano  kigk : 14/05/2012 numtip : 14/05/2012 bonus82 : 13/05/2012 momay : 13/05/2012 ploy171499 : 13/05/2012 kai2104 : 12/05/2012 ouizzzz : 11/05/2012