Page 1 of 1

changing editor to administrator

Posted: Tue Jul 03, 2007 4:57 pm
by jamesmusic
hello,

sorry if this is a silly question! but...

i'm the administrator of the blog, and have several editors filling in content, but for some reason i'm set as a chief editor when i should be set as administrator....anyone know if i can change this?

My user level is 1 - when ever i try to set it from editor to admin on the user settings page it says - 'You cannot create users with a higher userlevel than yourself'

Any ideas how to change this or is level 1 the highest?

many thanks,

james

Re: changing editor to administrator

Posted: Tue Jul 03, 2007 5:13 pm
by garvinhicking
Hi!

This might have happened because you might be using Serendipity 1.2-beta? There was a bug that reset your privileges when saving your personal preferences.

You can create this file called "fixrights.php" and call it via http://yourblog/fixrights.php:

Code: Select all

<?php
include 'serendipity_config.php';
serendipity_db_query("UPDATE {$serendipity['dbPrefix']}authors
                         SET userlevel     = 255,
                             right_publish = 1
                       WHERE authorid      = 1");

serendipity_db_query("UPDATE {$serendipity['dbPrefix']}config
                         SET value = 'false'
                       WHERE name  = 'no_create'
                         AND authorid = 1");
?>
This will set the User ID #1 to administrator again. You might need to replace this "1" with your actual user id.

HTH,
Garvin

Posted: Tue Jul 03, 2007 5:44 pm
by jamesmusic
thanks for that garvin, however i'm using serendipity-1.1.3
i did create a php file with the code you supplied, but i'm no expert in php and don't have much experience in implementing it...
....although i'm learning tons everyday since i've started with serendipity,
still i couldn't get the user settings to change to administrator.
Not sure what i'm doing wrong!
kind regards,
James

Posted: Tue Jul 03, 2007 5:52 pm
by garvinhicking
Hi!

The same script can help you, if in serendipity 1.1.3 you accidentally changed the userlevel yourself! :-)

Did you save the file and execute it to reset your privileges?

If you have access to phpMyAdmin, you could browse the serendipity_Authors table to see what your authorid is...

HTH,
Garvin

Posted: Tue Jul 03, 2007 6:39 pm
by jamesmusic
just one quick question, what should i set my user level too? which is the highest level? (e.g. user level 2?)
cheers!
J

Posted: Tue Jul 03, 2007 8:36 pm
by garvinhicking
Hi!

Userlevel 255 (like in fixpriv.php)

Regards,
Garvin