Php advanced variables

Source: Internet
Author: User
Php advanced variables

Error_reporting (0 );

Echo 'system type and version number: '. php_uname ().'
';

Echo 'system type: '. php_uname ('s'). 'or'. PHP_ OS .'
';

Echo 'system type version number: '. php_uname ('r ').'
';

Echo 'php running mode: '. php_sapi_name ().'
';

Echo 'current process username: '. Get_Current_User ().'
';

Echo 'php version: '. PHP_VERSION .'
';

Echo 'zend version: '. Zend_Version ().'
';

Echo 'php installation path: '. DEFAULT_INCLUDE_PATH .'
';

Echo 'absolute path of the current FILE: '. _ FILE __.'
';

Echo 'host value in HTTP request: '. $ _ SERVER ['http _ host'].'
';

Echo 'server IP: '. GetHostByName ($ _ SERVER ['server _ name']).'
';

Echo 'server IP address that receives the request: '. $ _ SERVER ['server _ ADDR'].'
'; # Sometimes it cannot be obtained, and GetHostByName ($ _ SERVER ['server _ name']) is more reliable;

Echo 'Client IP: '. $ _ SERVER ['remote _ ADDR'].'
';

Echo 'server interpretation engine: '. $ _ SERVER ['server _ soft'].'
';

Echo 'server CPU count: '. $ _ SERVER ['processop _ IDENTIFIER'].'
';

Echo 'server system directory: '. $ _ SERVER ['systemroot'].'
';

Echo 'server domain NAME: '. $ _ SERVER ['server _ name'].'
'; # $ _ SERVER ['http _ host'] is recommended.

Echo 'user domain name: '. $ _ SERVER ['userdomain'].'
';

Echo 'server language: '. $ _ SERVER ['http _ ACCEPT_LANGUAGE'].'
';

Echo 'server web PORT: '. $ _ SERVER ['server _ port'].'
';

?>


The result is as follows:

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.