Размер файла: 1.62Kb
<?
define('IN_SCRIPT', true);
include "ini.php";
include "includes/header.php";
print '<card title="Install"><p><small>';
if(mysql_query("
CREATE TABLE `users` (
`id` MEDIUMINT(8) NOT NULL auto_increment,
`user_name` VARCHAR(255) NOT NULL,
`user_pass` VARCHAR(255) NOT NULL,
`user_balance` VARCHAR(255) NOT NULL DEFAULT '0.7',
`user_last` INT(11) NOT NULL ,
`user_partner` MEDIUMINT(8) NOT NULL DEFAULT '1',
`user_free_credit` tinyint(1) NOT NULL default '1',
`user_address_book` text NOT NULL,
`user_num_sms` MEDIUMINT( 8 ) NOT NULL ,
PRIMARY KEY (`id`)
) TYPE=MyISAM AUTO_INCREMENT=1 ;
"))
print 'Users table-ok<br/>';
else print mysql_error().'<br/>';
if(mysql_query("
CREATE TABLE `sessions` (
`id` MEDIUMINT(8) NOT NULL auto_increment,
`sess_uid` MEDIUMINT(8) NOT NULL,
`sess_time` INT(11) NOT NULL,
`sess_sid` VARCHAR(255) NOT NULL,
PRIMARY KEY (`id`)
) TYPE=MyISAM AUTO_INCREMENT=1 ;
"))
print 'Sessions table-ok<br/>';
else print mysql_error().'<br/>';
if(mysql_query("
CREATE TABLE `logs` (
`id` MEDIUMINT(8) NOT NULL auto_increment,
`logs_browser` VARCHAR(255) NOT NULL,
`logs_ip` VARCHAR(255) NOT NULL,
PRIMARY KEY (`id`)
) TYPE=MyISAM AUTO_INCREMENT=1 ;
"))
print 'Logs table-ok<br/>';
else print mysql_error().'<br/>';
if(mysql_query("
CREATE TABLE `last_sms` (
`id` MEDIUMINT(8) NOT NULL auto_increment,
`last_order_id` MEDIUMINT(8) NOT NULL,
`last_uid` MEDIUMINT(8) NOT NULL,
`last_text` text NOT NULL,
PRIMARY KEY (`id`)
) TYPE=MyISAM AUTO_INCREMENT=1 ;
"))
print 'last sms table-ok<br/>';
else print mysql_error().'<br/>';
include "includes/footer.php";
mysql_close();
?>