TAILIEUCHUNG - Professional Information Technology-Programming Book part 80

Tham khảo tài liệu 'professional information technology-programming book part 80', công nghệ thông tin, kỹ thuật lập trình phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | Server Environment Variables Now let s look at the information that PHP allows you to find out from your web server. The _SERVER super-global array contains a number of elements that give information about the web server environment during the current page request. To see the full list within the context of a script you execute this statement at any time print_r _SERVER The examples in this section are common to most web servers. However some servers may not support all the values shown or may use different names. You can always refer to the output from the previous statement to check which values are available in your script. Script Information The name of the current script can be found in _SERVER SCRI PT_NAME . Knowing this name can be useful if you want to create a form that submits to itself but whose filename you might want to change in the future. You could use the following tag FORM ACTION- php print _SERVER SCRIPT_NAME METHOD POST Similar to SCRIPT_NAME is the REQUEST_URI element which contains the full uniform resource identifier of the page request. This consists of the full path to the current script including the question mark and values in the query string if there are any. The query string is not included as part of the SCRI PT_NAME element but you can access it on its own as _SERVER QUERY_STRING . If you want to find the domain name under which a script is running you can look at _SERVER HTTP_HOST . Your web server might be set up with several alias domains and this provides a way to see which domain name a visitor is viewing your pages on. User Information The HTTP USER AGENT element contains a string that identifies the user s web browser software and operating system. It might look like one of the following Mozilla compatible MSIE Windows NT SV1 Mozilla windows U Windows NT en-US rv Gecko 20041107 Firefox Lynx libwww-FM SSL-MM OpenSSL These three examples correspond to Internet Explorer .

TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.