Here is the basic statement that PHP obtains the current server information. PHP program version: <? PHP echo php_version;? >zend version: <? PHP echo zend_version (); >mysql support: <?php echo function_exists (mysql_close)? " Yes: "No";? >mysql database Persistent connection: <?php echo @get_cfg_var ("Mysql.allow_persistent")? " Yes "no"; >mysql maximum number of connections: <?php echo @get_cfg_var ("Mysql.max_links") ==-1? " Unlimited ": @get_cfg_var (" mysql.max_links ");? > server operating system: <? PHP echo php_os;?> server-side information: <? PHP echo $_server [' server_software '];?> max upload limit: <? PHP Echo Get_cfg_var ("Upload_max_filesize")? Get_cfg_var ("Upload_max_filesize"): "Upload attachments not allowed";?> maximum execution time: <? PHP Echo Get_cfg_var ("Max_execution_time"). " Seconds ";?> script run consumes maximum memory: <? PHP echo Get_cfg_var ("Memory_limit")? Get_cfg_var ("Memory_limit"): "None"?> query the version of the currently connected MySQL database php own function mysql_get_ Server_info () Obtains server system time Date_default_timezone_set (PRC); echo Date ("y-m-d g:i:s"); Query the version of the currently connected MySQL database PHP self-function mysql_get_server_info () Get Server System time Date_default_timezone_set (PRC) ; echo Date ("y-m-d g:i:s");
PHP Basic statement to get current server information