Textpattern Forum

You are not logged in. Register | Login | Help

#61 2011-08-23 10:12:54

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,399

Re: bot_privs: edit user level privileges

mmelon wrote:

…Does anybody happen to know how I might use this plugin to allow staff writers access to the admin tab for adi menu? the event is

Hi,
read the plugin code, around line 62 you’ll find the instructions for doing what you want.

BTW probably this plugin should be considered dead given that the new smd_user_manager does a lot more.

Offline

#62 2011-08-23 10:32:05

Gocom
Developer
Registered: 2006-07-14
Posts: 4,476
Website

Re: bot_privs: edit user level privileges

mmelon wrote:

Does anybody happen to know how I might use this plugin to allow staff writers access to the admin tab for adi menu? […] it resides in section but allowing access to section still results in restricted area.

If you want to use bot_privs, you will need to modify the source code of bot_privs. Alternatively you could (as easily) just directly modify adi_menu’s source code’s add_privs() statements to include the groups you want. Open adi_menu’s source code, search for add_privs from the code and change the list of numbers in the statement to include those you want.

If you want to use bot_privs, you will need to add the adi_menu’s privilege strings to the bot_privs’ $bot_used_privs array, i.e.

'adi_menu_admin' => 'Access adi_menu',

And then set wanted groups for the item via bot_privs’ user interface. You will also have to give same privileges for the main tab the adi_menu resides in, if the tab has stricter privileges.


Rah-plugins | What? I’m a little confused… again :-) <txp:is_god />

Offline

#63 2011-08-23 13:53:30

mmelon
Member
Registered: 2006-03-02
Posts: 64

Re: bot_privs: edit user level privileges

Hi Gocom,

Thanks very much for the reply. I would really love to be able to edit the php source of adi_menu but I am having lots of problems. It crashes when I try and save the plugin regardless of whether I have modified it or not. I really need to limit the sections it pulls into the admin table, and slightly modify the markup of the generated menus.

http://forum.textpattern.com/viewtopic.php?id=27778&p=20

I asked the author but he wasn’t able to help. Perhaps I can modify the plugin and inject the new source straight into the db using phpmyadmin?

Thanks again,
Mike

Offline

#64 2011-08-23 22:03:54

gomedia
Plugin Author
Registered: 2008-06-01
Posts: 900
Website

Re: bot_privs: edit user level privileges

mmelon has contacted me off-forum, so I’ll do what I can for him.

Offline

#65 2012-09-11 15:29:46

ecklesroad
Plugin Author
From: Bemidji, MN
Registered: 2008-02-22
Posts: 119
Website

Re: bot_privs: edit user level privileges

I like your plugin, it makes it really handy to update permissions on the fly without having to update the admin_config.php. I though your plugin needed a little css/js help in the list to make it look a little cleaner, so here’s an update. I added a new bot_css() function that adds some js and css to the head on bot privs’s tab

http://www.withremote.com/file_download/25/bot_privs_v0.3.2.php.zip

Feel free to add it to yours if you want.

Offline

#66 2012-09-11 16:00:32

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,399

Re: bot_privs: edit user level privileges

ecklesroad wrote:

… I added a new bot_css() function that adds some js and css to the head on bot privs’s tab

Thank you very much Nate!
I’ll add your function for sure when (if) I’ll release a new version. Consider anyway this is a semi-useless plugin after the release of smd_user_manager which is a lot more advanced.

Offline

#67 2012-09-12 14:36:51

ecklesroad
Plugin Author
From: Bemidji, MN
Registered: 2008-02-22
Posts: 119
Website

Re: bot_privs: edit user level privileges

I’ll have to check that one out!

Offline

#68 2012-09-12 15:30:14

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 5,868
Website

Re: bot_privs: edit user level privileges

redbot wrote:

smd_user_manager… is a lot more advanced.

Thanks for the recommendation although, ahem, it does need a visual spruce up since 4.5 came out. Still works, as far as I can tell.

It’s on me list, but it’s gonna be a long journey.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern.

Txp Builders – finely-crafted code, design and Txp

Offline

#69 2013-02-19 23:38:46

tye
Member
From: Pottsville, NSW
Registered: 2005-07-06
Posts: 813
Website

Re: bot_privs: edit user level privileges

I can’t quite believe this, but I have kind of fixed a small minor display problem :)

if you replace this line:

echo form(startTable('txp-list')

with this line

echo form(startTable('', '', 'txp-list')

then this plugin displays perfectly with the new admin themes… I can only guess that startTable has more arguments, one for a class rather than id

Offline

#70 2013-03-04 22:37:22

Avant La Lettre
Member
From: Zurich, Switzerland
Registered: 2011-10-03
Posts: 3
Website

Re: bot_privs: edit user level privileges

@tye, Thanks for that smart fix! Worked perfectly for me as well (Textpattern 4.5.4, bot_privs 0.3.2).

Quick note for anybody doing a quick search-and-replace:
The plugin’s original line is echo form(startTable('list') (not: txp-list) – the fix is echo form(startTable('', '', 'txp-list').

@redbot, please do continue to support bot_privs, and don’t consider it obsolete. I bet there are lots of people (like myself) that prefer a nicely packaged one-trick pony over something more complex and slightly overwhelming. (No offense to Stef, there are numerous plugins of yours I love dearly!). I’ve got bot_privs in use on multiple sites and would love to stick to it, for those and many txp installs to come.

Offline

Board footer

Powered by FluxBB