Location: PHPKode > scripts > Free Who is Online Script > who_is_online/install.php
<?php

// database info
include("config.inc.php");
$db_con = mysql_connect($hostname,$hostuser, $hostpass) or die("Connetion to database failed!");
    mysql_select_db($dbname);
mysql_query("DROP TABLE IF EXISTS new_online;") or die(mysql_error());
$query = "CREATE TABLE `new_online` (
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT ,
`time` INT UNSIGNED NOT NULL ,
`ip` VARCHAR( 15 ) NOT NULL ,
PRIMARY KEY ( `id` ) ,
INDEX ( `time` ) ,
INDEX ( `IP` )
);";
mysql_query($query) or die(mysql_error());
mysql_close();
echo "Installation complete! <font color=red><b>Delete this file!</b></font><br><br>";
?>
Return current item: Free Who is Online Script