Welcome to Tech Support Forum home to more then 136,000 problems solved. Issues have included: Spyware, Malware, Virus Issues, Windows, Microsoft, Linux, Networking, Security, Hardware, and Gaming Getting your problem solved is as easy as:
1. Registering for a free account
2. Asking your question
3. Receiving an answer

Registered members:
* Get free support
* Communicate privately with other members (PM).
* Removal of this message
* See fewer ads.
* And much more..

 





Want to know how to post a question? click here Having problems with spyware and pop-ups? First Steps
Go Back   Tech Support Forum > Design Forum > Web Serving and Management
User Name
Password
Site Map Register Donate Rules Blogs Mark Forums Read

Web Serving and Management how to web server support forum

Reply
 
Thread Tools
Old 07-05-2008, 09:21 AM   #1 (permalink)
Registered User
 
Join Date: Jul 2008
Posts: 1
OS: WIN XP


Mistake Please Help. Trouble creating tables in MySql.

Hi All,

I have a linux redhat operating system and I've been tring desperately for the past two weeks to install a custom cgi script that creates a bunch of tables related to my website.

If i access mysql via ssh I'm able to successfully login and create databases, tables and and add values.

I'm also able to populated existing tables in mysql via cgi or perl script and even create a table.

The script named install_mysql.cgi - installs a set of mysql tables into the mysql server for the domain name.

The install_msql.cgi -> calls an admin-list.inc file which in turns calls the config file containing the info for mysql, such as dbname, user, password, and host and the iSubs.pm (module) file that aides in the building of the mysql tables.

The problem that I'm facing is rather strange: When I run the install_mysql.cgi from the browser, I get a message saying "The MySQL Database has been setup properly".

but when I check the error log on my server I see the following messages:

Code:
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::st execute failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 188.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::st fetchrow_hashref failed: fetch() without execute() at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 220.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::st execute failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 188.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::st fetchrow_hashref failed: fetch() without execute() at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 220.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_advertisers' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_books' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_members' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_messages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_messages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_messages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::db do failed: Invalid default value for 'id' at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 182.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::st execute failed: Table 'myfunlotto.lotto_pages' doesn't exist at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 188.
[Fri Jul 04 13:19:27 2008] [error] [client 68.84.40.48] [Fri Jul 4 13:19:27 2008] install_mysql.cgi: DBD::mysql::st fetchrow_hashref failed: fetch() without execute() at /var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files/iSubs.pm line 220.
iSubs.pm file:

Code:
iSubs.pm file:

sub OpenMySQL {
use DBI;
$dbh = DBI->connect("DBI:mysql:$mysql_db:$mysql_host",$mysql_u,$mysql_p) or die $DBI::errstr;
$mysqlopen = 1;
return; }

sub CloseMySQL {
$dbh->disconnect();
$mysqlclosed = 1;
return; }

sub DoMySQL {
if (!$mysqlopen) { &OpenMySQL; }
$dbh->do("$_[0]");
return; }

sub PrepareMySQL {
if (!$mysqlopen) { &OpenMySQL; }
$result = $dbh->prepare("$_[0]");
$result->execute();
return; }

install_mysql.cgi


Code:
#!/usr/bin/perl

use CGI::Carp qw(fatalsToBrowser);
require "admin-list.inc";

$section = "Setting Up the MySQL Database ...";
&PrintHead;
&DoMySQL("CREATE TABLE $advtable (id int(10)  DEFAULT '' NOT NULL auto_increment, userid varchar(35)  DEFAULT '' NOT NULL , password varchar(35)  DEFAULT '' NOT NULL , company varchar(75)    , url varchar(255)    , email varchar(75)  DEFAULT '' NOT NULL , fullname varchar(75)  DEFAULT '' NOT NULL , orders int(10)  DEFAULT '0' NOT NULL , totalspent float  DEFAULT '0' NOT NULL , extra1 varchar(75)    , extra2 varchar(75)    , extra3 varchar(75)    , PRIMARY KEY (id), KEY custid (id))");
&DoMySQL("INSERT  INTO $advtable (id,userid,password,company,url,email,fullname,orders,totalspent,extra1,extra2,extra3) VALUES('1','admin','$adminpassword','$site_name','$clickthru_url','$admin_email','$admin_name','0','0','','','')");
&DoMySQL("CREATE TABLE $bookstable (id int(24)  DEFAULT '' NOT NULL auto_increment, userid varchar(35)  DEFAULT '' NOT NULL , refclicks int(24)  DEFAULT '0' NOT NULL , referrals int(24)  DEFAULT '0' NOT NULL , tickets_played int(24)  DEFAULT '0' NOT NULL , tickets_avail int(24)  DEFAULT '0' NOT NULL , tickets_won int(24)  DEFAULT '0' NOT NULL , PRIMARY KEY (id), UNIQUE userid (userid))");
&DoMySQL("INSERT  INTO $bookstable (id,userid,refclicks,referrals,tickets_played,tickets_avail,tickets_won) VALUES('1','admin','0','0','0','100','0')");
&DoMySQL("CREATE TABLE $drawtable (id int(10)  DEFAULT '' NOT NULL auto_increment, win_number int(3)  DEFAULT '0' NOT NULL , win_date varchar(50)  DEFAULT '' NOT NULL , win_time varchar(50)  DEFAULT '' NOT NULL , win_ip varchar(50)  DEFAULT '' NOT NULL , winners int(10)  DEFAULT '0' NOT NULL , PRIMARY KEY (id))");
&DoMySQL("CREATE TABLE $memtable (id int(9)  DEFAULT '' NOT NULL auto_increment, userid varchar(35)  DEFAULT '' NOT NULL , password varchar(35)  DEFAULT '' NOT NULL , first varchar(35)  DEFAULT '' NOT NULL , last varchar(35)  DEFAULT '' NOT NULL , email varchar(125)  DEFAULT '' NOT NULL , city varchar(125)    , state char(2)    , zipcode varchar(125)    , notes text    , status varchar(75)  DEFAULT '' NOT NULL , estatus varchar(75)  DEFAULT '' NOT NULL , vcode varchar(128)    , ipadd varchar(50)  DEFAULT '' NOT NULL , referrer varchar(35)    , PRIMARY KEY (id), UNIQUE userid (userid), KEY id (id))");
&DoMySQL("INSERT  INTO $memtable (id,userid,password,first,last,email,city,state,zipcode,notes,status,estatus,vcode,ipadd,referrer) VALUES('1','admin','$admin_password','$admin_name','($site_name)','$admin_email','Your City','FL','33713',NULL,'ACTIVE','VERIFIED','','$ipadd','')");
&DoMySQL("CREATE TABLE $msgtable (id int(10)  DEFAULT '' NOT NULL auto_increment, messageid varchar(50)  DEFAULT '' NOT NULL , contents longtext  DEFAULT '' NOT NULL , lastedited varchar(255)  DEFAULT '' NOT NULL , description longtext    , PRIMARY KEY (id), UNIQUE messageid (messageid), KEY id (id))");
&DoMySQL("INSERT  INTO $msgtable (id,messageid,contents,lastedited,description) VALUES('1','Verify Email','Hi ~firstname~,\n\nIn order for you to start using your account you must\nclick on the email verification link included below.\n\nEmail Verification Link:\n~cgibin~/verify.cgi?~vcode~\n\n\nAdmin,\n~sitename~','','Email Verification Link Message')");
&DoMySQL("INSERT  INTO $msgtable (id,messageid,contents,lastedited,description) VALUES('2','Password Resend','Hi ~firstname~,\n\nHere is your login information as requested by you or some\none at ~ipaddress~.\n\nUser ID: ~userid~\nPassword: ~password~\n\n\nAdmin,\n~sitename~','','Password Resend Email Message')");
&DoMySQL("INSERT  INTO $msgtable (id,messageid,contents,lastedited,description) VALUES('3','Winner Notification','Congratulations ~firstname~, You have WON!!\r\n\r\nDetails and Prize Redeeming Instructions go here.\r\n','','This is the member winning ticket notification email.  Here add the instructions on how to redeem the prize you are offering for winning.')");
&DoMySQL("CREATE TABLE $orderstable (id int(10)  DEFAULT '' NOT NULL auto_increment, userid varchar(35)  DEFAULT '' NOT NULL , linkid varchar(25)    , linkurl text  DEFAULT '' NOT NULL , linktype varchar(128)    , linkxtra text    , maxclicks int(10)  DEFAULT '0' NOT NULL , status varchar(128)  DEFAULT '' NOT NULL , datedone varchar(12)    , clicks int(11)  DEFAULT '0' NOT NULL , PRIMARY KEY (id))");
&DoMySQL("CREATE TABLE $htmtable (id int(10)  DEFAULT '' NOT NULL auto_increment, pageid varchar(255)  DEFAULT '' NOT NULL , contents longtext  DEFAULT '' NOT NULL , lastedited varchar(255)  DEFAULT '' NOT NULL , description varchar(255)    , PRIMARY KEY (id), KEY id (id))");
&DoMySQL("INSERT  INTO $htmtable (id,pageid,contents,lastedited,description) VALUES('1','Referral Banners Page','Banner Option #1:\r\nBanner #1 HTML Code:<p align=\"center\"><a href=\"~cgibin~/p.cgi?~userid~/index.html\" target=\"_blank\"><img src=\"/imgs/banner_001.gif\" border=\"0\"></a></p>','','Banners you want your members to use for promting your Lotto Site.  Use (~cgibin~/p.cgi?~userid~/index.html) where you want the referral link displayed.')");
&DoMySQL("INSERT  INTO $htmtable (id,pageid,contents,lastedited,description) VALUES('2','Banner Code', 'Add banner code here for the banner you want displayed when advertisers are not shown.', '', 'Default Banner Code for ALL your pages')");
&DoMySQL("INSERT  INTO $htmtable (id,pageid,contents,lastedited,description) VALUES('3','Template Header', '<TABLE WIDTH=750 BORDER=0 CELLPADDING=0 CELLSPACING=0 align=&quot;center&quot;>\r\n  <TR> \r\n    <TD COLSPAN=2> <IMG SRC=&quot;http://www.myfunlotto.com/images/lotto_01.jpg&quot; WIDTH=141 HEIGHT=80 ALT=&quot;&quot;></TD>\r\n    <TD COLSPAN=11 background=&quot;http://www.myfunlotto.com/images/lotto_02.jpg&quot;> \r\n      <table width=&quot;90%&quot; border=&quot;0&quot; cellspacing=&quot;0&quot; cellpadding=&quot;10&quot; align=&quot;center&quot;>\r\n        <tr> \r\n          <td><font face=&quot;Arial, Helvetica, sans-serif&quot; size=&quot;4&quot;><b><font color=&quot;#FFFFFF&quot;>www.myfunlotto.com<br>\r\n            <font size=&quot;3&quot;>Just Play & Win!</font></font></b></font></td>\r\n        </tr>\r\n      </table>\r\n    </TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=1 HEIGHT=80 ALT=&quot;&quot;></TD>\r\n  </TR>\r\n  <TR> \r\n    <TD COLSPAN=4> <a href=&quot;http://www.myfunlotto.com&quot;><IMG SRC=&quot;http://www.myfunlotto.com/images/lotto_03.jpg&quot; WIDTH=170 HEIGHT=29 ALT=&quot;&quot; border=&quot;0&quot;></a></TD>\r\n    <TD COLSPAN=3> <a href=&quot;http://www.myfunlotto.com/cgi-bin/signup.cgi&quot;><IMG SRC=&quot;http://www.myfunlotto.com/images/lotto_04.jpg&quot; WIDTH=131 HEIGHT=29 ALT=&quot;&quot; border=&quot;0&quot;></a></TD>\r\n    <TD> <a href=&quot;http://www.myfunlotto.com/login.html&quot;><IMG SRC=&quot;http://www.myfunlotto.com/images/lotto_05.jpg&quot; WIDTH=103 HEIGHT=29 ALT=&quot;&quot; border=&quot;0&quot;></a></TD>\r\n    <TD COLSPAN=3> <a href=&quot;http://www.myfunlotto.com/cgi-bin/advert/signup.cgi&quot;><IMG SRC=&quot;http://www.myfunlotto.com/images/lotto_06.jpg&quot; WIDTH=155 HEIGHT=29 ALT=&quot;&quot; border=&quot;0&quot;></a></TD>\r\n    <TD COLSPAN=2> <a href=&quot;http://www.myfunlotto.com/advert/login.html&quot;><IMG SRC=&quot;http://www.myfunlotto.com/images/lotto_07.jpg&quot; WIDTH=191 HEIGHT=29 ALT=&quot;&quot; border=&quot;0&quot;></a></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=1 HEIGHT=29 ALT=&quot;&quot;></TD>\r\n  </TR>\r\n  <TR> \r\n    <TD COLSPAN=13 align=&quot;left&quot; valign=&quot;top&quot;>', '', 'Top part of the HTML Coding for EVERY page made thru the script.')");
&DoMySQL("INSERT  INTO $htmtable (id,pageid,contents,lastedited,description) VALUES('4','Template Footer', ' </TD><HTML>\r\n    <HEAD>\r\n    <TITLE>www.myfunlotto.com FREE LOTTO</TITLE>\r\n    </HEAD>\r\n    <BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=1 HEIGHT=8 ALT=&quot;&quot;></TD>\r\n  </TR>\r\n  <TR> \r\n    <TD colspan=&quot;13&quot; bgcolor=&quot;#000000&quot;>\r\n      <div align=&quot;center&quot;><font face=&quot;Arial, Helvetica, sans-serif&quot; size=&quot;2&quot; color=&quot;#FFFFFF&quot;>Copyright \r\n        www.myfunlotto.com 2004</font></div>\r\n    </TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=1 HEIGHT=37 ALT=&quot;&quot;></TD>\r\n  </TR>\r\n  <TR> \r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=87 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=54 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=8 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=21 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=5 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=73 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=53 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=103 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=44 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=11 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=100 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=20 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD> <IMG SRC=&quot;http://www.myfunlotto.com/images/spacer.gif&quot; WIDTH=171 HEIGHT=1 ALT=&quot;&quot;></TD>\r\n    <TD></TD>\r\n  </TR>\r\n</TABLE></body></html>', '', 'Bottom part of the HTML Coding for EVERY page made thru the script.')");
&DoMySQL("INSERT  INTO $htmtable (id,pageid,contents,lastedited,description) VALUES('5','Members Main Page','Welcome to the ~sitename~ Members Section!  Put information about the prizes you are offering here.','','HTML Coding you want displayed on the members section main page.')");
&DoMySQL("INSERT  INTO $htmtable (id,pageid,contents,lastedited,description) VALUES('6','Advertisers Main Page','Welcome to the ~sitename~ Advertisers Section!','','HTML Coding you want displayed on the advertisers section main page.')");
&DoMySQL("CREATE TABLE $ticketstable (id int(10)  DEFAULT '' NOT NULL auto_increment, userid varchar(35)  DEFAULT '' NOT NULL , a int(1)  DEFAULT '0' NOT NULL , b int(1)  DEFAULT '0' NOT NULL , c int(1)  DEFAULT '0' NOT NULL , status varchar(28)  DEFAULT '' NOT NULL , ipadd varchar(50)  DEFAULT '' NOT NULL , dateplayed varchar(50)  DEFAULT '' NOT NULL , extra varchar(255)    , PRIMARY KEY (id))");
&DoMySQL("CREATE TABLE $tracktable (id int(10)  DEFAULT '' NOT NULL auto_increment, userid varchar(35)  DEFAULT '' NOT NULL , ipadd varchar(50)  DEFAULT '' NOT NULL , linkid varchar(25)  DEFAULT '' NOT NULL , date varchar(12)  DEFAULT '' NOT NULL , time varchar(15)  DEFAULT '' NOT NULL , PRIMARY KEY (id))");
print "<p> &nbsp;&nbsp; </p>\n";
print "<p><b>The MySQL Database has been setup properly</b></p>\n";
print "<p> &nbsp;&nbsp; </p>\n";
&PrintFoot;
exit;

admin.inc file:
-------------


Code:
#
################################################################################
$datadir = "/var/www/vhosts/myfunlotto.com/httpdocs/lotto/data_files";
require "$datadir/iConfig.pm";
require "$datadir/iSubs.pm";

1;

During the initial setup of the script there were 3 .inc files where the default value for $datadir had to be changed to where the folder data_files exists on my server.
i would really really appreciate your expert advice and kind help in resolving this matter.

Regards,
Jerry!
jerry000 is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Bookmark on Thread SoupReddit!
Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT -7. The time now is 03:58 AM.



Copyright 2001 - 2008, Tech Support Forum

Search Engine Friendly URLs by vBSEO

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82