changing editor to administrator

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
jamesmusic
Regular
Posts: 46
Joined: Thu Jun 28, 2007 6:50 pm
Contact:

changing editor to administrator

Post 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
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: changing editor to administrator

Post 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
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
jamesmusic
Regular
Posts: 46
Joined: Thu Jun 28, 2007 6:50 pm
Contact:

Post 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
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post 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
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
jamesmusic
Regular
Posts: 46
Joined: Thu Jun 28, 2007 6:50 pm
Contact:

Post 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
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi!

Userlevel 255 (like in fixpriv.php)

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply