How to display your server infomation!
Posted: Wed Jun 13, 2007 3:47 pm
This is something that I thought would be usefull if you followed designstudios server tutorial, this would display some infomation about your server.Very Happy
Well first...You should check your PHP info...So create a PHP file and add this:
[PHP]
<?php
phpinfo();
?> [/PHP]
Now...If this doesn't show up anything...You havn't installed PHP correctly.Very Happy
Now...I will display how you can make a page displaying your server infomation + your visitors infomation...+ I will add a nice CSS style with it.Very Happy
Done!!!
Well first...You should check your PHP info...So create a PHP file and add this:
[PHP]
<?php
phpinfo();
?> [/PHP]
Now...If this doesn't show up anything...You havn't installed PHP correctly.Very Happy
Now...I will display how you can make a page displaying your server infomation + your visitors infomation...+ I will add a nice CSS style with it.Very Happy
Code: Select all
<html>
<head>
<title>Server + Your infomation - Yoursite.com</title>
<style type="text/css">
body
{
background-color:#003366;color:#0066FF;font-family:Verdana
}
</style>
</head>
<body>
<?php
echo "Server Infomation:";
echo "
Server Name: $_SERVER[SERVER_NAME]
IP Address: $_SERVER[SERVER_ADDR]
**** Root: $_SERVER[****_ROOT]
Server Software: $_SERVER[SERVER_SOFTWARE]";
echo 'Current PHP Version: ' . phpversion();
echo "
Your Infomation:";
echo "
Your IP Address: $_SERVER[REMOTE_ADDR]
Your Host Name: $_SERVER[REMOTE_HOST]
";
?>
</body>
</html>
Done!!!