Jump to content

Duplicating modules in phpnuke


systemtek

Recommended Posts

I am using phpnuke and i have read in the manual about Duplicating the PHP-Nuke FAQ module, this is section 22.1. 

Here : http://www.karakas-online.de/EN-Book/duplicating-php-nuke-faq-module.html

This is just what i need to do, but reading about it, it says about doing stuff from the command line to the MySQL.

I dont have command line access i just have mysql and phpnuke via cPanel, do i need to do any of that, if so how do i go about doing it as dont have ssh access.

Are the files anywhere i acn access them ?

Thanks
Link to comment
Share on other sites

[quote author=systemtek link=topic=103843.msg413823#msg413823 date=1155297781]
I am using phpnuke and i have read in the manual about Duplicating the PHP-Nuke FAQ module, this is section 22.1. 

Here : http://www.karakas-online.de/EN-Book/duplicating-php-nuke-faq-module.html

This is just what i need to do, but reading about it, it says about doing stuff from the command line to the MySQL.

I dont have command line access i just have mysql and phpnuke via cPanel, do i need to do any of that, if so how do i go about doing it as dont have ssh access.

Are the files anywhere i acn access them ?

Thanks
[/quote]

Looks like you can just run the following in from the SQL tab in phpMyAdmin and it'll create the 2 tables in your database - which means you can skip the MySQL Prompt portion. So do the following:

copy the below code. Open phpMyAdmin and select your phpnuke databaes. Click on the SQL tab and paste the code in the RUN SQL QUERY window and click GO. That'll create the 2 tables that you need.

[code]
#
# Table structure for table `nuke_faqAnswer2`
#
 
CREATE TABLE nuke_faqAnswer2 (
  id tinyint(4) NOT NULL auto_increment,
  id_cat tinyint(4) NOT NULL default '0',
  question varchar(255) default ",
  answer text,
  PRIMARY KEY  (id),
  KEY id (id),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `nuke_faqAnswer2`
#
# --------------------------------------------------------
#
# Table structure for table `nuke_faqCategories2`
#
CREATE TABLE nuke_faqCategories2 (
  id_cat tinyint(3) NOT NULL auto_increment,
  categories varchar(255) default NULL,
  flanguage varchar(30) NOT NULL default ",
  PRIMARY KEY  (id_cat),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `nuke_faqCategories2`
#
# --------------------------------------------------------
[/code]
Link to comment
Share on other sites

Hi thanks for the reply, tried as suggested and get the following error

#1075 - Incorrect table definition; there can be only one auto column and it must be defined as a key

Any ideas ?

Here is my code i just changed it and called it products :

#
# Table structure for table `nuke_products`
#
 
CREATE TABLE nuke_products (
  id tinyint(4) NOT NULL auto_increment,
  id_cat tinyint(4) NOT NULL default '0',
  question varchar(255) default ",
  answer text,
  PRIMARY KEY  (id),
  KEY id (id),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `nuke_products`
#
# --------------------------------------------------------
#
# Table structure for table `nuke_products`
#
CREATE TABLE nuke_products (
  id_cat tinyint(3) NOT NULL auto_increment,
  categories varchar(255) default NULL,
  flanguage varchar(30) NOT NULL default ",
  PRIMARY KEY  (id_cat),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `products`
#
# --------------------------------------------------------
Link to comment
Share on other sites

  • 2 years later...
In your code,

CREATE TABLE nuke_products (
  id tinyint(4) NOT NULL auto_increment,
  id_cat tinyint(4) NOT NULL default '0',
  question varchar(255) default ",
  answer text,
  PRIMARY KEY  (id),
  KEY id (id),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `nuke_products`
#
# --------------------------------------------------------
#
# Table structure for table `nuke_products`
#
CREATE TABLE nuke_products (
  id_cat tinyint(3) NOT NULL auto_increment,
  categories varchar(255) default NULL,
  flanguage varchar(30) NOT NULL default ",
  PRIMARY KEY  (id_cat),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `products`
#
# --------------------------------------------------------

the table names you are creating are SAME!!
add 2 to the end of the second table name.

like this:

CREATE TABLE nuke_products (
  id tinyint(4) NOT NULL auto_increment,
  id_cat tinyint(4) NOT NULL default '0',
  question varchar(255) default ",
  answer text,
  PRIMARY KEY  (id),
  KEY id (id),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `nuke_products`
#
# --------------------------------------------------------
#
# Table structure for table `nuke_products`
#
CREATE TABLE nuke_products2 (
  id_cat tinyint(3) NOT NULL auto_increment,
  categories varchar(255) default NULL,
  flanguage varchar(30) NOT NULL default ",
  PRIMARY KEY  (id_cat),
  KEY id_cat (id_cat)
) TYPE=MyISAM;
#
# Dumping data for table `products`
#
# --------------------------------------------------------

Karkas guide is not good because it is so out-of-dated.
That doesn't help you a lot and most of nuke persons.
Link to comment
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.