#! /usr/bin/php
<HTML>
<HEAD>
<TITLE>Who's on the Virtual Server</TITLE>
</HEAD>
<BODY>
<center><table border=0 cellspacing=0 width=600><tr><td>
<b><font face=arial size=+1>
Who's on the Virtual Server
</font></b>
<font face=arial size=-1>
<br>Last Updated <?php print(date("m/d/y h:i")) ?>
CST
<br><br>Note: links on some sites may show up broken because of the way
they are being called.
Many sites are not in english and would require
the correct character set being used on your computer, see settings in
Windows.</td></tr></table></center>
<?php
/*
Title: Server.php
Wriiten by: Marcus Xenakis marcus@xenakis.net
This script works on Unix servers and uses the "ls" command.
It displays all of the users in the home directory of a Virtual Host.
The script is set up for a 4 column table of 600 pixel width.
This works best for the lowest common user 640x480.
There are only two lines to change for more columns, see text.
The table is centered on larger displays.
*/
// change the following line to your root server
$host = "http://earth.communitech.net/~";
if ($type == "d") {
if (strlen($dire) < 25) {
if (strlen($name) > 1) {
$site = $site + 1;
$array[$site] = "$site <a href=\"$host$name\">$name</a><br>";
}
}
}
}
/* For more columns:
Change the "cols" value from 4 to whatever you wish.
Then change the value "$i + 4 to match what you specified
in the "cols" parameter. You may also need to change the
table width to more pixels (currently 600) or change it
to a percentage value, e.g. witdth=\"100%\".
*/
echo "<pre><center><TABLE BORDER COLS=4 WIDTH=\"600\" >";
for ($i = 1; $i <= $site; $i = $i + 4) {