Jump to content

Recommended Posts

I have this file:

<?php
include ('includes/db.php');

if(isset($_POST['submit'])){

   $sitename = $_POST['sitename'];
   $url = $_POST['url'];
   $theme = $_POST['theme'];
   


mysql_query("CREATE TABLE IF NOT EXISTS `comments` (
  `com_id` int(11) NOT NULL auto_increment,
  `page_id` int(11) NOT NULL default '0',
  `com_name` varchar(50) NOT NULL default '',
  `com_comment` text NOT NULL,
  `com_cat` varchar(10) NOT NULL default '',
  `com_date` int(11) NOT NULL default '0',
  `ip` varchar(255) NOT NULL,
  PRIMARY KEY  (`com_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=3302 ;");


mysql_query("CREATE TABLE IF NOT EXISTS `favorites` (
  `id` int(11) NOT NULL auto_increment,
  `username` varchar(255) NOT NULL,
  `pageid` bigint(11) NOT NULL,
  `pagecat` varchar(255) NOT NULL,
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=31 ;");

mysql_query("CREATE TABLE IF NOT EXISTS `feedback` (
  `fb_id` int(11) NOT NULL auto_increment,
  `fb_email` varchar(50) NOT NULL default '',
  `fb_message` text NOT NULL,
  `fb_date` int(11) NOT NULL default '0',
  PRIMARY KEY  (`fb_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=10 ;");

mysql_query("CREATE TABLE IF NOT EXISTS `game` (
  `game_id` int(11) NOT NULL auto_increment,
  `game_name` varchar(150) NOT NULL default '',
  `game_link` varchar(888) NOT NULL,
  `game_thumb` varchar(255) NOT NULL,
  `game_des` text NOT NULL,
  `game_cat` varchar(100) NOT NULL default '',
  `game_type` varchar(255) NOT NULL,
  `game_views` int(11) NOT NULL default '0',
  PRIMARY KEY  (`game_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=583 ;");


mysql_query("INSERT INTO `game` (`game_id`, `game_name`, `game_link`, `game_thumb`, `game_des`, `game_cat`, `game_type`, `game_views`) VALUES
(1, 'Drag Racer V3', 'http://toxicflash.com/swf/f-619.swf', 'http://arcadecredits.com/thumbs/1.gif', '', 'racing', 'e', 27),
(2, 'Stunt Pilot', 'stuntpilot.swf', 'stuntpilotmedicon.jpg', 'Be the best Stunt Pilot and complete all the courses without crashing!', 'action', 'h', 10),
(3, 'Doomland 2154', 'doomland_con.swf', 'Doomland 2154.jpg', 'Shoot em up time crisis style in this amazing 3d shooter, Doomland 2154.', 'shooter', 'h', 3),
(4, 'Big Truck Adventures 2', 'bigtruckadventures2-swf.swf', 'Big Truck Adventures 2.jpg', '', 'racing', 'h', 48),
(5, 'Happy Tree Friends: Flippy Attack', 'Flippy Attack.swf', 'Flippy Attack.png', 'The objective of this game is simple. Stay alive as long as possible. Using characters from Happy Tree Friends.', 'Action', 'h', 14),
(6, 'Hamster Ball', 'hamsterball.swf', 'Hamster Ball.jpg', 'The objective of the game is to move the hamsterball to the orange flag and stop there as quickly as possible. Make sure you avoid the spikes and pitfalls so the poor hamster dosent die. Make sure you collect the stars on the way! Enjoy!', 'Adventure', 'h', '2');");



mysql_query("CREATE TABLE IF NOT EXISTS `game_cat` (
  `cat_id` int(11) NOT NULL auto_increment,
  `cat_name` varchar(100) NOT NULL default '',
  PRIMARY KEY  (`cat_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=10 ;");

mysql_query("INSERT INTO `game_cat` (`cat_id`, `cat_name`) VALUES
(1, 'Action'),
(2, 'Adventure'),
(3, 'Racing'),
(4, 'Shooter');");


mysql_query("CREATE TABLE IF NOT EXISTS `joke` (
  `joke_id` int(11) NOT NULL auto_increment,
  `joke_name` varchar(150) NOT NULL default '',
  `joke_joke` text NOT NULL,
  `joke_cat` varchar(50) NOT NULL default '',
  `joke_by` varchar(255) NOT NULL,
  `joke_view` int(11) NOT NULL default '0',
  `joke_date` int(11) NOT NULL default '0',
  PRIMARY KEY  (`joke_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=176 ;");


mysql_query("CREATE TABLE IF NOT EXISTS `joke_cat` (
  `jokecat_id` int(11) NOT NULL auto_increment,
  `jokecat_cat` varchar(150) NOT NULL default '',
  PRIMARY KEY  (`jokecat_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=19 ;");


mysql_query("INSERT INTO `joke_cat` (`jokecat_id`, `jokecat_cat`) VALUES
(1, 'Adult Jokes'),
(2, 'Animal Jokes'),
(3, 'Bar Jokes'),
(4, 'Blonde Jokes'),
(5, 'Computer Jokes'),
(6, 'Dirty Jokes'),
(8, 'Funny Quotes'),
(9, 'Knock Knock Jokes'),
(10, 'Lawyer Jokes'),
(11, 'Medical Jokes'),
(12, 'Misc Jokes'),
(13, 'Redneck Jokes'),
(14, 'Relationship Jokes'),
(15, 'Religious Jokes'),
(16, 'Yo Mama Jokes');");


mysql_query("CREATE TABLE IF NOT EXISTS `pm` (
  `id` bigint(20) NOT NULL auto_increment,
  `from` varchar(255) NOT NULL,
  `to` varchar(255) NOT NULL,
  `subject` varchar(255) NOT NULL,
  `message` text NOT NULL,
  `parentid` bigint(20) NOT NULL default '0',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=8 ;");

mysql_query("CREATE TABLE IF NOT EXISTS `settings` (
  `id` varchar(2) NOT NULL,
  `sitename` varchar(255) NOT NULL,
  `url` varchar(255) NOT NULL,
  `status` varchar(255) NOT NULL,
  `topads` text NOT NULL,
  `bottomads` text NOT NULL,
  `theme` varchar(255) NOT NULL,
  `rpp` varchar(100) NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;");

       mysql_query("INSERT INTO settings SET 
                url='$url',
                id='1',
                status='online',
                theme='$theme',
                sitename='$sitename');") or die(mysql_error());



mysql_query("CREATE TABLE IF NOT EXISTS `users` (
  `id` int(10) unsigned NOT NULL auto_increment,
  `type` varchar(10) NOT NULL default '2',
  `status` varchar(255) NOT NULL,
  `gameplays` int(11) NOT NULL default '0',
  `first` varchar(32) NOT NULL,
  `last` varchar(32) NOT NULL,
  `username` varchar(32) NOT NULL,
  `password` varchar(255) NOT NULL,
  `email` varchar(255) NOT NULL,
  `avatar` varchar(255) NOT NULL default 'default.gif',
  `location` varchar(255) NOT NULL,
  `myspace` varchar(255) NOT NULL,
  `aim` varchar(255) NOT NULL,
  `yim` varchar(255) NOT NULL,
  `about` text NOT NULL,
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ;");


mysql_query("INSERT INTO `users` (`id`, `type`, `status`, `gameplays`, `first`, `last`, `username`, `password`, `avatar`, `about`) VALUES

(1, '1', 'offline', 0, 'billy', 'bob', 'admin', '21232f297a57a5a743894a0e4a801fc3', 'default.gif', 'I am the admin!....');") or die(mysql_error());



mysql_query("CREATE TABLE IF NOT EXISTS `video_cat` (
  `vid_id` int(11) NOT NULL auto_increment,
  `vid_cat` varchar(250) NOT NULL default '',
  `vid_count` int(11) NOT NULL default '0',
  PRIMARY KEY  (`vid_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=8 ;");


mysql_query("INSERT INTO `video_cat` (`vid_id`, `vid_cat`) VALUES
(1, 'autos'),
(2, 'comedy'),
(3, 'sports'),
(4, 'music'),
(5, 'education'),
(6, 'news');");



mysql_query("CREATE TABLE IF NOT EXISTS `video` (
  `video_id` int(11) NOT NULL auto_increment,
  `video_name` varchar(250) NOT NULL default '',
  `video_link` varchar(250) NOT NULL default '',
  `video_des` text NOT NULL,
  `video_cat` varchar(50) NOT NULL default '',
  `video_views` int(11) NOT NULL default '0',
  `video_by` varchar(255) NOT NULL,
  PRIMARY KEY  (`video_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=56 ;");


mysql_query("INSERT INTO `video` (`video_id`, `video_name`, `video_link`, `video_des`, `video_cat`, `video_views`, `video_by`) VALUES
(1, 'Numa Numa', '60og9gwKh1o', '', 'Comedy', 248, ''),
(2, 'Shrek Karaoke', 'gknjvqdB_1M', '', 'Music', 82, ''),
(3, 'Eminem - Beautiful', 'pCzRei9-42s', '', 'music', 26, 'admin'),
(4, 'Call of Duty: Modern Warfare 2 Trailer', 'P7vyLDEwF5I', '', 'news', 15, 'admin'),
(5, 'Michael Jackson - Billie Jean', 'CaAD7EizAfw', '', 'music', 16, 'admin'),
(6, 'Michael Jackson - Beat It', 'jyCiNAgfcUs', '', 'music', 11, 'admin'),
(7, 'sponge bob - pump it', 'fYIeLApUUlI', 'music video for sponge bob pump it by black eyed peas', 'music', 2, 'Admin'),
(8, 'Spongebob We Will Rock You', 'OkrMnu9k4-A', 'Spongebob and his friends singin We Will Rock You, from Queen', 'music', 8, 'Admin'),
(9, 'Michael Jackson - They Dont Really Care About Us', 'ZPFFDSChedY', 'The last song he preformed before his death.', '', 30, 'Admin');");




mysql_query("CREATE TABLE IF NOT EXISTS `vote` (
  `id` int(4) NOT NULL auto_increment,
  `username` varchar(255) NOT NULL,
  `pageid` int(11) default NULL,
  `pagecat` varchar(255) NOT NULL,
  `rating` int(11) default NULL,
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=16 ;");



      echo '<div class="done">Updated.</div><br />
      Please delete the install.php file. <br /><br />Username: __ Password: __<br />
      These are to login to the admin panel (default admin account). CHANGE THEM ASAP!!! ';
      exit;
   
}


echo "<form action='install.php' method='POST'>

         <div class='header'>Settings</div>
   Site Name:<br />   
   <input type='text' name='sitename' size='40'><br />

   Domain:   
   <input type='text' name='url' size='40' value='http://'><br />
         
   Theme:
   <input type='text' name='theme' size='40' value='default' readonly><br />

   <input type='submit' name='submit' value='Install Media Script!'>
   </form>";
?>

 

But when I try to install it, it spits out this error:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 6

 

I dont seem to see what might be wrong on line 6...

 

Any help would be greatly appreciated!

Thanks!  :)

Link to comment
https://forums.phpfreaks.com/topic/165828-solved-install-help/
Share on other sites

The line number is the line of the query where the sql error was detected. It would also really help if you pointed out which query was failing.

 

I'll guess it is this one -

 

       mysql_query("INSERT INTO settings SET 
                url='$url',
                id='1',
                status='online',
                theme='$theme',
                sitename='$sitename');") or die(mysql_error());

 

The error message is complaining about the right syntax to use near ')'. I only see one ')' in the actual query string. It probably does not belong there at all.

 

Edit: This is the syntax prototype for the INSERT syntax you are using -

 

INSERT [LOW_PRIORITY | DELAYED | HIGH_PRIORITY] [iGNORE]

    [iNTO] tbl_name

    SET col_name={expr | DEFAULT}, ...

    [ ON DUPLICATE KEY UPDATE

      col_name=expr

        [, col_name=expr] ... ]

 

Link to comment
https://forums.phpfreaks.com/topic/165828-solved-install-help/#findComment-874679
Share on other sites

Ok thanks, it works now sort of but im getting this error:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(`url`, `id`, `status`, `theme`,`sitename`) VALUES ('http://mediascript.freehost' at line 1

 

File now looks like:

<?php
include ('includes/db.php');

if($_POST['submit']){

   $sitename = protect($_POST['sitename']);
   $url = protect($_POST['url']);
   $theme = protect($_POST['theme']);
   


mysql_query("CREATE TABLE IF NOT EXISTS `comments` (
  `com_id` int(11) NOT NULL auto_increment,
  `page_id` int(11) NOT NULL default '0',
  `com_name` varchar(50) NOT NULL default '',
  `com_comment` text NOT NULL,
  `com_cat` varchar(10) NOT NULL default '',
  `com_date` int(11) NOT NULL default '0',
  `ip` varchar(255) NOT NULL,
  PRIMARY KEY  (`com_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=3302 ;");


mysql_query("CREATE TABLE IF NOT EXISTS `favorites` (
  `id` int(11) NOT NULL auto_increment,
  `username` varchar(255) NOT NULL,
  `pageid` bigint(11) NOT NULL,
  `pagecat` varchar(255) NOT NULL,
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=31 ;");

mysql_query("CREATE TABLE IF NOT EXISTS `feedback` (
  `fb_id` int(11) NOT NULL auto_increment,
  `fb_email` varchar(50) NOT NULL default '',
  `fb_message` text NOT NULL,
  `fb_date` int(11) NOT NULL default '0',
  PRIMARY KEY  (`fb_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=10 ;");

mysql_query("CREATE TABLE IF NOT EXISTS `game` (
  `game_id` int(11) NOT NULL auto_increment,
  `game_name` varchar(150) NOT NULL default '',
  `game_link` varchar(888) NOT NULL,
  `game_thumb` varchar(255) NOT NULL,
  `game_des` text NOT NULL,
  `game_cat` varchar(100) NOT NULL default '',
  `game_type` varchar(255) NOT NULL,
  `game_views` int(11) NOT NULL default '0',
  PRIMARY KEY  (`game_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=583 ;");


mysql_query("INSERT INTO `game` (`game_id`, `game_name`, `game_link`, `game_thumb`, `game_des`, `game_cat`, `game_type`, `game_views`) VALUES
(1, 'Drag Racer V3', 'http://toxicflash.com/swf/f-619.swf', 'http://arcadecredits.com/thumbs/1.gif', '', 'racing', 'e', 27),
(2, 'Stunt Pilot', 'stuntpilot.swf', 'stuntpilotmedicon.jpg', 'Be the best Stunt Pilot and complete all the courses without crashing!', 'action', 'h', 10),
(3, 'Doomland 2154', 'doomland_con.swf', 'Doomland 2154.jpg', 'Shoot em up time crisis style in this amazing 3d shooter, Doomland 2154.', 'shooter', 'h', 3),
(4, 'Big Truck Adventures 2', 'bigtruckadventures2-swf.swf', 'Big Truck Adventures 2.jpg', '', 'racing', 'h', 48),
(5, 'Happy Tree Friends: Flippy Attack', 'Flippy Attack.swf', 'Flippy Attack.png', 'The objective of this game is simple. Stay alive as long as possible. Using characters from Happy Tree Friends.', 'Action', 'h', 14),
(6, 'Hamster Ball', 'hamsterball.swf', 'Hamster Ball.jpg', 'The objective of the game is to move the hamsterball to the orange flag and stop there as quickly as possible. Make sure you avoid the spikes and pitfalls so the poor hamster dosent die. Make sure you collect the stars on the way! Enjoy!', 'Adventure', 'h', '2');");



mysql_query("CREATE TABLE IF NOT EXISTS `game_cat` (
  `cat_id` int(11) NOT NULL auto_increment,
  `cat_name` varchar(100) NOT NULL default '',
  PRIMARY KEY  (`cat_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=10 ;");


mysql_query("INSERT INTO `game_cat` (`cat_id`, `cat_name`) VALUES
(1, 'Action'),
(2, 'Adventure'),
(3, 'Racing'),
(4, 'Shooter');");




mysql_query("CREATE TABLE IF NOT EXISTS `joke` (
  `joke_id` int(11) NOT NULL auto_increment,
  `joke_name` varchar(150) NOT NULL default '',
  `joke_joke` text NOT NULL,
  `joke_cat` varchar(50) NOT NULL default '',
  `joke_by` varchar(255) NOT NULL,
  `joke_view` int(11) NOT NULL default '0',
  `joke_date` int(11) NOT NULL default '0',
  PRIMARY KEY  (`joke_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=176 ;");


mysql_query("CREATE TABLE IF NOT EXISTS `joke_cat` (
  `jokecat_id` int(11) NOT NULL auto_increment,
  `jokecat_cat` varchar(150) NOT NULL default '',
  PRIMARY KEY  (`jokecat_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=19 ;");


mysql_query("INSERT INTO `joke_cat` (`jokecat_id`, `jokecat_cat`) VALUES
(1, 'Adult Jokes'),
(2, 'Animal Jokes'),
(3, 'Bar Jokes'),
(4, 'Blonde Jokes'),
(5, 'Computer Jokes'),
(6, 'Dirty Jokes'),
(8, 'Funny Quotes'),
(9, 'Knock Knock Jokes'),
(10, 'Lawyer Jokes'),
(11, 'Medical Jokes'),
(12, 'Misc Jokes'),
(13, 'Redneck Jokes'),
(14, 'Relationship Jokes'),
(15, 'Religious Jokes'),
(16, 'Yo Mama Jokes');");


mysql_query("CREATE TABLE IF NOT EXISTS `pm` (
  `id` bigint(20) NOT NULL auto_increment,
  `from` varchar(255) NOT NULL,
  `to` varchar(255) NOT NULL,
  `subject` varchar(255) NOT NULL,
  `message` text NOT NULL,
  `parentid` bigint(20) NOT NULL default '0',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=8 ;");

mysql_query("CREATE TABLE IF NOT EXISTS `settings` (
  `id` varchar(2) NOT NULL,
  `sitename` varchar(255) NOT NULL,
  `url` varchar(255) NOT NULL,
  `status` varchar(255) NOT NULL,
  `topads` text NOT NULL,
  `bottomads` text NOT NULL,
  `theme` varchar(255) NOT NULL,
  `rpp` varchar(100) NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;");


mysql_query("INSERT INTO settings SET (`url`, `id`, `status`, `theme`,`sitename`) VALUES
('$url', '1', 'online', '$theme', '$sitename');") or die(mysql_error());



mysql_query("CREATE TABLE IF NOT EXISTS `users` (
  `id` int(10) unsigned NOT NULL auto_increment,
  `type` varchar(10) NOT NULL default '2',
  `status` varchar(255) NOT NULL,
  `gameplays` int(11) NOT NULL default '0',
  `first` varchar(32) NOT NULL,
  `last` varchar(32) NOT NULL,
  `username` varchar(32) NOT NULL,
  `password` varchar(255) NOT NULL,
  `email` varchar(255) NOT NULL,
  `avatar` varchar(255) NOT NULL default 'default.gif',
  `location` varchar(255) NOT NULL,
  `myspace` varchar(255) NOT NULL,
  `aim` varchar(255) NOT NULL,
  `yim` varchar(255) NOT NULL,
  `about` text NOT NULL,
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ;");

mysql_query("INSERT INTO `users` (`id`, `type`, `status`, `gameplays`, `first`, `last`, `username`, `password`, `avatar`, `about`) VALUES

(1, '1', 'offline', 0, 'billy', 'bob', 'admin', '21232f297a57a5a743894a0e4a801fc3', 'default.gif', 'I am the admin!....');") or die(mysql_error());


mysql_query("CREATE TABLE IF NOT EXISTS `video_cat` (
  `vid_id` int(11) NOT NULL auto_increment,
  `vid_cat` varchar(250) NOT NULL default '',
  `vid_count` int(11) NOT NULL default '0',
  PRIMARY KEY  (`vid_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=8 ;");


mysql_query("INSERT INTO `video_cat` (`vid_id`, `vid_cat`) VALUES
(1, 'autos'),
(2, 'comedy'),
(3, 'sports'),
(4, 'music'),
(5, 'education'),
(6, 'news');");



mysql_query("CREATE TABLE IF NOT EXISTS `video` (
  `video_id` int(11) NOT NULL auto_increment,
  `video_name` varchar(250) NOT NULL default '',
  `video_link` varchar(250) NOT NULL default '',
  `video_des` text NOT NULL,
  `video_cat` varchar(50) NOT NULL default '',
  `video_views` int(11) NOT NULL default '0',
  `video_by` varchar(255) NOT NULL,
  PRIMARY KEY  (`video_id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=56 ;");

mysql_query("INSERT INTO `video` (`video_id`, `video_name`, `video_link`, `video_des`, `video_cat`, `video_views`, `video_by`) VALUES
(1, 'Numa Numa', '60og9gwKh1o', '', 'Comedy', 248, ''),
(2, 'Shrek Karaoke', 'gknjvqdB_1M', '', 'Music', 82, ''),
(3, 'Eminem - Beautiful', 'pCzRei9-42s', '', 'music', 26, 'admin'),
(4, 'Call of Duty: Modern Warfare 2 Trailer', 'P7vyLDEwF5I', '', 'news', 15, 'admin'),
(5, 'Michael Jackson - Billie Jean', 'CaAD7EizAfw', '', 'music', 16, 'admin'),
(6, 'Michael Jackson - Beat It', 'jyCiNAgfcUs', '', 'music', 11, 'admin'),
(7, 'sponge bob - pump it', 'fYIeLApUUlI', 'music video for sponge bob pump it by black eyed peas', 'music', 2, 'Admin'),
(8, 'Spongebob We Will Rock You', 'OkrMnu9k4-A', 'Spongebob and his friends singin We Will Rock You from Queen', 'music', 8, 'Admin'),
(9, 'Michael Jackson - They Dont Really Care About Us', 'ZPFFDSChedY', 'The last song he preformed before his death.', '', 30, 'Admin');");




mysql_query("CREATE TABLE IF NOT EXISTS `vote` (
  `id` int(4) NOT NULL auto_increment,
  `username` varchar(255) NOT NULL,
  `pageid` int(11) default NULL,
  `pagecat` varchar(255) NOT NULL,
  `rating` int(11) default NULL,
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=16 ;");



      echo '<div class="done">Updated.</div><br />
      Please delete the install.php file. <br /><br />Username: admin Password: admin<br />
      These are to login to the admin panel (default admin account). CHANGE THEM ASAP!!! ';
      exit;
   
}


echo "<form action='install.php' method='POST'>

         <div class='header'>Settings</div>
   Site Name:<br />   
   <input type='text' name='sitename' size='40'><br />

   Domain:   
   <input type='text' name='url' size='40' value='http://'><br />
         
   Theme:
   <input type='text' name='theme' size='40' value='default' readonly><br />

   <input type='submit' name='submit' value='Install Media Script!'>
   </form>";
?>

Link to comment
https://forums.phpfreaks.com/topic/165828-solved-install-help/#findComment-874696
Share on other sites

This is the syntax prototype for that INSERT syntax -

 

INSERT [LOW_PRIORITY | DELAYED | HIGH_PRIORITY] [iGNORE]

    [iNTO] tbl_name [(col_name,...)]

    {VALUES | VALUE} ({expr | DEFAULT},...),(...),...

    [ ON DUPLICATE KEY UPDATE

      col_name=expr

        [, col_name=expr] ... ]

 

Link to comment
https://forums.phpfreaks.com/topic/165828-solved-install-help/#findComment-874701
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.