Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: Change Role on the fly when logged in for testing
Myself and another user, both of us Publishers, have been using this pretty heavily the last few days. Not one single hitch. :) Really handy.
We have thought it might be nice if it were possible to set the toggle outside of the main nav in the Admin: In the same position that the drop-down navigation for the classic theme is. This way, you could be examining any one of the tabs using any role and look at that same tab again and again as other types of user (roles).
It’s in a great spot now as it’s accessible under any role but wanted to suggest the concept. Perhaps it’s doable? One might register a top level tab called ‘Switch Role’ as the drop-down point of clicking but then is it possible for sub ‘tabs’ to perform the switch?
txtstrap (Textpattern + Twitter Bootstrap + etc…)
Offline
Re: Change Role on the fly when logged in for testing
whaleen wrote:
Not one single hitch. :) Really handy.
Excellent, glad to hear it.
We have thought it might be nice if it were possible to set the toggle outside of the main nav in the Admin
I did think about this earlier but couldn’t figure out a nice way to do it. Plugins can’t create new top-level tabs (as far as I know…)
But if you download the plugin again and edit it to apply your user list, you’ll find a second editable parameter underneath that one.
If you leave the 2nd param at 0
it works as it does now (i.e. on its own Admin tab). If, however, you alter it and specify a pair of x, y
co-ords, the dropdown will appear on the screen on ALL tabs at that (absolute) position. You can also just specify one value if you wish to only set the ‘x’ position — the ‘y’ will assume 0 (top edge).
In the process of making these changes I’ve also fixed that annoying “feature” where you had to click away to some other screen to see the changes to the tabs in the header. Now it alters them directly and immediately, which is much nicer (IE6/7 may have issues with this, but Firefox and Opera play nicely).
Try that and see how it works for ya. BTW, it’s TXP 4.2.0+ only now, since it uses pluggable_ui()
.
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Online
#15 2010-04-11 14:42:49
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,313
Re: Change Role on the fly when logged in for testing
Bloke wrote:
the dropdown will appear on the screen on ALL tabs
Thanks for this cool improvement, Stef, you should have seen me smile!
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
Re: Change Role on the fly when logged in for testing
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Online
Re: Change Role on the fly when logged in for testing
I am no longer able to login and see my Admin, Extensions, Plugins, etc tabs.
I was testing out various access options using Switch Role plugin, and while i was switched to “Staff Writer” I logout… but when i try to logon again as Admin my Admin ID is still stuck i nstaff writer!! I can i reset. I can’t login to see admin tabs?
Last edited by bici (2012-11-18 00:20:22)
…. texted postive
Offline
#18 2012-11-18 00:34:18
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,313
Re: Change Role on the fly when logged in for testing
Did you install v0.1 of smd_faux_role?
I think the closest you get to a solution is this post by Stef. Sounds like a doable PHPmyAdmin affair.
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
Re: Change Role on the fly when logged in for testing
uli wrote:
Did you install v0.1 of smd_faux_role?
I think the closest you get to a solution is this post by Stef. Sounds like a doable PHPmyAdmin affair.
well i must have 0.20 installed
('smd_faux_role',1,'Stef Dawson','stefdawson.com/','0.20','Switch user privs on the fly so you can see what other accounts see'
I thought I would try a restore a DB from backup.
And so I just downloaded the DB.sql file from a backup done last month. and lo and behold i came across the line posted above.
Last edited by bici (2012-11-18 00:42:00)
…. texted postive
Offline
#20 2012-11-18 01:12:47
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,313
Re: Change Role on the fly when logged in for testing
OK, I think you should tell Stef in the topic I linked to about the issue here.
In order to fix your privs, I meant you should go into PHPmyAdmin, table txp_users
, column privs
, and set the value for your login back to 1.
Last edited by uli (2012-11-18 01:13:23)
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
Re: Change Role on the fly when logged in for testing
uli wrote:
OK, I think you should tell Stef in the topic I linked to about the issue here.
In order to fix your privs, I meant you should go into PHPmyAdmin, table
txp_users
, columnprivs
, and set the value for your login back to 1.
i posted on the thread. And i was able to restore my admin login. Thank-you
Last edited by bici (2012-11-18 17:28:00)
…. texted postive
Offline