Author |
Message |
Goon
New Member


Joined: Sep 22, 2003
Posts: 7
|
Posted:
Fri Oct 10, 2003 12:14 am |
|
Hey Raven... cool site... I need a little help here...
I was wondering, I installed the 6.8 version with fixes (I think you had it on here) and whenever I try to add another admin I get an error:
Code:Column count doesn't match value count at row 1
|
I'm pretty sure it uses
Code:$sql = "INSERT INTO ".$prefix."_authors VALUES ('$name', '$the_adm', '$url', '$email', '$pwd', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '1', '')";
|
(thats in admin.php) to add new admins...
and here's mysql table:
Code:CREATE TABLE nuke_authors (
aid varchar(25) NOT NULL default '',
name varchar(50) default NULL,
url varchar(255) NOT NULL default '',
email varchar(255) NOT NULL default '',
pwd varchar(40) default NULL,
counter int(11) NOT NULL default '0',
radminarticle tinyint(2) NOT NULL default '0',
radmintopic tinyint(2) NOT NULL default '0',
radminuser tinyint(2) NOT NULL default '0',
radminsurvey tinyint(2) NOT NULL default '0',
radminsection tinyint(2) NOT NULL default '0',
radminlink tinyint(2) NOT NULL default '0',
radminephem tinyint(2) NOT NULL default '0',
radminfaq tinyint(2) NOT NULL default '0',
radmindownload tinyint(2) NOT NULL default '0',
radminreviews tinyint(2) NOT NULL default '0',
radminnewsletter tinyint(2) NOT NULL default '0',
radminforum tinyint(2) NOT NULL default '0',
radmincontent tinyint(2) NOT NULL default '0',
radminency tinyint(2) NOT NULL default '0',
radmingroup tinyint(2) NOT NULL default '0',
radminsuper tinyint(2) NOT NULL default '1',
admlanguage varchar(30) NOT NULL default '',
PRIMARY KEY (aid),
KEY aid (aid)
) TYPE=MyISAM;
|
So I was wondering if you could help me out here... tnx. |
Last edited by Goon on Fri Oct 10, 2003 2:43 pm; edited 1 time in total |
|
|
 |
Goon

|
Posted:
Fri Oct 10, 2003 12:15 am |
|
Oh and one more thing... dunno if this helps but I can change info in the God Admin... |
|
|
|
 |
fury
Worker


Joined: Sep 09, 2003
Posts: 165
|
Posted:
Sat Oct 11, 2003 10:47 am |
|
one thing about the God Admin account is that you have to be logged in with that account to be able to change it. try this and see if it works for you and let us know. I will look into your other problem and resond later today
Thanks
Fury |
|
|
|
 |
fury

|
Posted:
Sat Oct 11, 2003 10:48 am |
|
the other problem also goes with the second you must be logged in as The God Admin account to add more admins.
Thanks
Fury |
|
|
|
 |
Goon

|
Posted:
Sat Oct 11, 2003 12:44 pm |
|
Hey Fury, tnx for the response...
See, right now, I have only one admin, God Admin. I probably forgot to say that I own the site. But the thing is, that I can't add other admins and get "Column count doesn't match value count at row 1" whenever I try to.
tnx. |
|
|
|
 |
Goon

|
Posted:
Sat Oct 11, 2003 12:51 pm |
|
I even tried replacing admin.php (renaming the original to admin_backup.php), and making another nuke_authors entry in mysql (renaming the original to nuke_authors_backup)... I got the create new admin page whenever I went to admin.php but when i tried to accualy make a god admin, it just returned to back to the same page... Then I just replaced nuke_authors to the original and everything when back the way it was... I guess you can't really make a God Admin after it's already been made in the past (do you know if PHP-Nuke checks another mysql entry for if God Admin has already been made ?)... Maybe the counter in nuke_authors has to be auto_increment ? I'm not really a master at mysql so I'm just shooting out ideas...
Tnx. |
|
|
|
 |
Goon

|
Posted:
Sat Oct 11, 2003 1:11 pm |
|
Maybe there's a way to add admins throught mysql ? |
|
|
|
 |
fury

|
Posted:
Sat Oct 11, 2003 1:46 pm |
|
if you are using phpmyadmin you can try inserting an admin that way and see if it shows up let me think for a bit and i have to run an errand and i will respond when i get back
thanks
Fury |
|
|
|
 |
Raven
Site Admin/Owner

Joined: Aug 27, 2002
Posts: 17088
|
Posted:
Sun Oct 12, 2003 10:30 am |
|
Goon wrote: | Hey Fury, tnx for the response...
See, right now, I have only one admin, God Admin. I probably forgot to say that I own the site. But the thing is, that I can't add other admins and get "Column count doesn't match value count at row 1" whenever I try to.
tnx. | Is it possible that you added a module that has added a column to your nuke_authors table? Some mods add a column but don't remember to update some core modules that need to know that information for inserts. Use phpMyAdmin and count the columns actually in the table and see if it's the same number as in your create staement. |
|
|
|
 |
Goon

|
Posted:
Mon Oct 13, 2003 10:21 pm |
|
Thanks Raven...
I'll try that, and tell you what is the result... |
|
|
|
 |
Goon

|
Posted:
Tue Oct 14, 2003 3:56 pm |
|
Hey Raven...
I found the bug...
You were right... It was probably one of the modules I installed that added a new row to nuke_authors and here it is:
Code:
Field | Type | Attributes | Null | Default | Extra
radminblocker | tinyint(2) | | No | 0 | |
|
Anyways... I simply added another 0 value into admin/modules/authors.php in swich($op) fucntion under "AddAuthor"...
And that worked... I'd just like to know if it hasn't opened any leaks into my mysql database...
Tnx.. |
|
|
|
 |
Raven

|
Posted:
Tue Oct 14, 2003 4:02 pm |
|
You're probably ok, but if it were me I'd try to find what module it is  |
|
|
|
 |
|