Page 1 of 1

How to display your server infomation!

Posted: Wed Jun 13, 2007 3:47 pm
by blue-sky
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

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!!!

Posted: Wed Jun 13, 2007 6:08 pm
by sakhan
useful thanks for sharing

Hmmmmmm

Posted: Fri Nov 09, 2007 8:08 pm
by estine
what are you talking about???? im not the best at web design lol

Posted: Sat Nov 10, 2007 9:46 am
by Tails5
He's talking about displaying stuff like the server version, and the IP of the user on a web page.

script

Posted: Thu Nov 29, 2007 12:54 pm
by Gebbo
hmm.. i neva knew you could do that with php but from that it looks very interesting :) might make something like that..

Posted: Fri Nov 30, 2007 12:56 am
by Tails5
Infact, there's something like that in the phpBB3 Admin panel, it includes all the information about your server :)

Posted: Sun Dec 02, 2007 12:02 pm
by jasondsouza
well no wonder ... php is one of the best server side scripting language.. It can do anything and everything...

Posted: Mon Dec 03, 2007 3:19 pm
by Tails5
The only one better in my opinion is ASPX, but that's not strictly server side... it depends on your starting line, if you do <form id="form1" runat="server"> for Server Side, and set runat="client" for clientside :)

script

Posted: Tue Dec 18, 2007 6:14 pm
by Gebbo
nice it looks very good i might actually use that =)

Posted: Sun Dec 30, 2007 5:50 pm
by Gio
Ty man for that script;) yust need it