Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
'Multi User 1.4' Plugin
Firstly, thanks for the great plugin.

Any progress on the password change bug?
Quote:after login with restricted user, he changed his own password, afte saving all restrictions getting lost ...
he can access all tabs.

The temporary fix of hiding the Settings tab becomes a problem when a user resets a forgotten password from the login page, because from then on when logging into admin they are presented with a link reminding them to change their password. With the Settings tab hidden that link can't be followed, which confuses the user.
Reply
I have been testing around and this is a list of the few glitch that I notice :
  • the links in footer are still present for a restricted user (except 'support') but I think it's because of the user language different from English. Maybe testing on the filename (they don't change) from the link would avoid the translation problem
  • There no undo possibility in user management. That could be a good idea to add
  • if a landing page had been chosen previously, its stay memorized when you create a new user (seems limited to the case of the last user of the list)
  • when you look at a user (edit) the landing page menu show the filename of the page (where the blank is if not selected), not just its name (like in the menu) and the corresponding name also appears, so you got them twice.
  • when saving changes on permission for a user without htmleditor :
Code:
Notice: Undefined variable: NHTMLEDITOR in C:\xampplite\htdocs\GS_BMT\plugins\user-managment.php on line 221
Your changes have been saved.
=> to resolve that add
Code:
else $NHTMLEDITOR = "";
to the end of
Code:
if (isset($_POST['usereditor'])) {
          $NHTMLEDITOR = $_POST['usereditor'];
      }
About the password change bug: in the core it doesn't just modify the user.xml, GS archived it and recreate a new one with the new settings. I sent mikeh a possible solution for that
about this mikeh, I notice that my little fix-it seems to interfere with the call to multiuser_perms() after you've save the setting. All the tab are visible again even though the access is denied

Neverless thank you for your work, this is a useful plugin
Sorry my English is poor, I'm working on it
Reply
Great plugin!
Also waiting for the "restricted user saving preferences bug" to be solved.
Lithie Wrote:I have been testing around and this is a list of the few glitch that I notice :
the links in footer are still present for a restricted user (except 'support') but I think it's because of the user language different from English. Maybe testing on the filename (they don't change) from the link would avoid the translation problem
I think that links are useless while they are present in tabs.
I've just cleared footer.php (except three last lines) and all is good Smile
Reply
Very nice plugin any word on how to fix the save settings issue where when a user saves the settings page it lets him have all rights again? I would love to see this bug get fixed.

Thanks for the plugin it's great.
Reply
Hi !

I have try this plugin today with GetSimple 3.1B r551

I was perfectly able to create and manage a test user, but this user can't login.
It's propably not a user/password problem as there is no errors messages, il just that
the user get stuck at the login page. The default admin user can still login correctly.

Sincerely
Reply
miniwark Wrote:Hi !

I have try this plugin today with GetSimple 3.1B r551

I was perfectly able to create and manage a test user, but this user can't login.
It's propably not a user/password problem as there is no errors messages, il just that
the user get stuck at the login page. The default admin user can still login correctly.

Sincerely

Did you block access to the "Pages" page? This is usually the mistake that causes the user to be blocked from logging in.
Reply
Josparky Wrote:Very nice plugin any word on how to fix the save settings issue where when a user saves the settings page it lets him have all rights again? I would love to see this bug get fixed.

Thanks for the plugin it's great.

Well for now you can just block access to the settings page. In most cases here shouldn't be anything the user should need to change there, except maybe their language and password.
Reply
mikeh Wrote:
miniwark Wrote:Hi !

I have try this plugin today with GetSimple 3.1B r551

I was perfectly able to create and manage a test user, but this user can't login.
It's propably not a user/password problem as there is no errors messages, il just that
the user get stuck at the login page. The default admin user can still login correctly.

Sincerely

Did you block access to the "Pages" page? This is usually the mistake that causes the user to be blocked from logging in.

No, i have created a test user with no blocking at all. Of course, now than i try again it's working perfectly. I certainly have made a mistake somewhere. I will try tomorrow with a fresh install just for check, but let assume than it's working Smile
Reply
I am ready to release version 1.4 (with settings page fix in place).

However, I do not want to release it without fixing the javascript error in IE.
I would greatly appreciate some help with this as I have spent countless hours trying to figure it out.

If you are unfamiliar with the error:
In any version of IE when you are on the "Manage Users" page and try to click the "Edit" button next to a user, it crashes IE.
Reply
very weird alright, some sort of infinite loop happening with the

$(".hide-divadmin").slideDown();

Call....

Strange thing it only happens in ie9 standards mode.
My Github Repos: Github
Website: DigiMute
Reply
hey, got it sorted.

Just change line 538 to

Code:
echo "\$(\".hide-div$xml->USR\").css('display','inline');";

and lines 548 and 555 to
Code:
echo "\$(\".hide-div$xml->USR\").css('display','none');";

no idea why the other isn't working... have seen some stuff online regarding ie9 crashing when manipulating tables/tbody with slidedown.

But that seems to be working fine in IE but seems to have messed up the table in Chrome.
My Github Repos: Github
Website: DigiMute
Reply
n00dles101 Wrote:echo "\$(\".hide-div$xml->USR\").css('display','inline');";

Thank you man.. You have no idea how much time I have killed trying to work this out.
However, version 1.4 has the coding re-done to oop and the line numbers are not even close to matching Smile
Would you mind putting in a before and after?
Reply
its the begin jquery script
change it to this...

Code:
// begin Jquery
      echo "<script type=\"text/javascript\">";

      //For Each User XML Filed, Print jQuery To Show/Hide The 'Edit User' And 'Add User' Sections
      foreach (glob($dir) as $file) {
          $xml = simplexml_load_file($file) or die("Unable to load XML file!");
          echo "\$(\".edit-user$xml->USR\").click(function () {";
          echo "\n";
          echo "\$(\".edit-user$xml->USR\").slideUp();";
          echo "\n";
          echo "\$(\".hide-user$xml->USR\").slideDown();";
          echo "\n";
          echo "\$(\".hide-div$xml->USR\").css('display','block');";
          echo "\n";
          echo "});";
          echo "\n";
          echo "\$(\".hide-user$xml->USR\").click(function () {";
          echo "\n";
          echo "\$(\".edit-user$xml->USR\").slideDown();";
          echo "\n";
          echo "\$(\".hide-user$xml->USR\").slideUp();";
          echo "\n";
          echo "\$(\".hide-div$xml->USR\").css('display','none');";
          echo "\n";
          echo "});";
          echo "\$(\"hideagain\").click(function () {";
          echo "\n";
          echo "\$(\".edit-user$xml->USR\").slideUp();";
          echo "\n";
          echo "\$(\".hide-div$xml->USR\").css('display','none');";
          echo "\n";
          echo "});";
          echo "\$(\"#add-user\").click(function () {";
          echo "\n";
          echo "\$(\"#add-user\").slideUp();";
          echo "\n";
          echo "\$(\".hide-div\").slideDown();";
          echo "\n";
          echo "});";
      }
      echo "</script>";
My Github Repos: Github
Website: DigiMute
Reply
n00dles101 Wrote:its the begin jquery script
change it to this...

Code:
// begin Jquery
      echo "<script type=\"text/javascript\">";

      //For Each User XML Filed, Print jQuery To Show/Hide The 'Edit User' And 'Add User' Sections
      foreach (glob($dir) as $file) {
          $xml = simplexml_load_file($file) or die("Unable to load XML file!");
          echo "\$(\".edit-user$xml->USR\").click(function () {";
          echo "\n";
          echo "\$(\".edit-user$xml->USR\").slideUp();";
          echo "\n";
          echo "\$(\".hide-user$xml->USR\").slideDown();";
          echo "\n";
          echo "\$(\".hide-div$xml->USR\").css('display','block');";
          echo "\n";
          echo "});";
          echo "\n";
          echo "\$(\".hide-user$xml->USR\").click(function () {";
          echo "\n";
          echo "\$(\".edit-user$xml->USR\").slideDown();";
          echo "\n";
          echo "\$(\".hide-user$xml->USR\").slideUp();";
          echo "\n";
          echo "\$(\".hide-div$xml->USR\").css('display','none');";
          echo "\n";
          echo "});";
          echo "\$(\"hideagain\").click(function () {";
          echo "\n";
          echo "\$(\".edit-user$xml->USR\").slideUp();";
          echo "\n";
          echo "\$(\".hide-div$xml->USR\").css('display','none');";
          echo "\n";
          echo "});";
          echo "\$(\"#add-user\").click(function () {";
          echo "\n";
          echo "\$(\"#add-user\").slideUp();";
          echo "\n";
          echo "\$(\".hide-div\").slideDown();";
          echo "\n";
          echo "});";
      }
      echo "</script>";

Awesome, thanks.
Reply
I released V1.4 today. Below are the changes:

Version 1.4 (12/15/2011)
- Fixed "Manage User" Form In All Versions Of IE - Previously clicking the "Edit" link for a user crashed IE
- Fixed Occasional Error That Occurred When Resetting Password From Front End
- Re-Coded Entire Plugin For Easier Future Updating & Community Collaboration
- Added "Update This Plugin" Button Which Will Update The Plugin To The Newest Version In Extend
- Fixed Problem With Settings Page
Previously changing the password from the settings page would overwrite permissions.
- Various Other Changes And Improvements

Settings Page Fix Info
Many of you are aware of the previous issue where if a user changes their password or any info on the GS "Settings" page, their permissions would be removed and they were allowed to access every area.
This was due to a missing hook in the get-simple core. This hook was added in a new version of the GS V3.1B.

If You Are Not Using GS V3.1B:
  • open admin/settings.php
  • Around Line 125 paste the following code:
Code:
<?php exec_action('settings-user'); ?>

Hint: Paste the above code right after you see the below code:
Code:
$xml->addChild('LANG', $LANG);
Reply
I would like to make language files for this plugin. I would appreciate any assistance in the translations Smile
Reply
Quote:If You Are Not Using GS V3.1B:

open admin/settings.php

Around Line 125 paste the following code:

<?php exec_action('settings-user'); ?>

Hint: Paste the above code right after you see the below code:

$xml->addChild('LANG', $LANG);

I tried this but I get a syntax error when I add it under the line you said? Would it go right before this (# create website xml file) instead? Can you help I have version 3.0 and here is the code below from line 114 to 131 please help? Thanks

Where do I put it.

Code:
$xml = new SimpleXMLElement('<item></item>');
        $xml->addChild('USR', $USR);
        $xml->addChild('PWD', $PASSWD);
        $xml->addChild('EMAIL', $EMAIL);
        $xml->addChild('HTMLEDITOR', $HTMLEDITOR);
        $xml->addChild('TIMEZONE', $TIMEZONE);
        $xml->addChild('LANG', $LANG);
        if (! XMLsave($xml, GSUSERSPATH . $file) ) {
            $error = i18n_r('CHMOD_ERROR');
        }
        
        # create website xml file
        createBak($wfile, GSDATAOTHERPATH, GSBACKUPSPATH.'other/');
        $xmls = new SimpleXMLExtended('<item></item>');
        $note = $xmls->addChild('SITENAME');
        $note->addCData($SITENAME);
        $note = $xmls->addChild('SITEURL');
        $note->addCData($SITEURL);
Reply
Josparky Wrote:
Quote:If You Are Not Using GS V3.1B:

open admin/settings.php

Around Line 125 paste the following code:

<?php exec_action('settings-user'); ?>

Hint: Paste the above code right after you see the below code:

$xml->addChild('LANG', $LANG);

I tried this but I get a syntax error when I add it under the line you said? Would it go right before this (# create website xml file) instead? Can you help I have version 3.0 and here is the code below from line 114 to 131 please help? Thanks

Where do I put it.

Code:
$xml = new SimpleXMLElement('<item></item>');
        $xml->addChild('USR', $USR);
        $xml->addChild('PWD', $PASSWD);
        $xml->addChild('EMAIL', $EMAIL);
        $xml->addChild('HTMLEDITOR', $HTMLEDITOR);
        $xml->addChild('TIMEZONE', $TIMEZONE);
        $xml->addChild('LANG', $LANG);
        if (! XMLsave($xml, GSUSERSPATH . $file) ) {
            $error = i18n_r('CHMOD_ERROR');
        }
        
        # create website xml file
        createBak($wfile, GSDATAOTHERPATH, GSBACKUPSPATH.'other/');
        $xmls = new SimpleXMLExtended('<item></item>');
        $note = $xmls->addChild('SITENAME');
        $note->addCData($SITENAME);
        $note = $xmls->addChild('SITEURL');
        $note->addCData($SITEURL);


Sorry about the typo:
code should not include the php brackets:
Code:
exec_action('settings-user');

Code:
$xml = new SimpleXMLElement('<item></item>');
        $xml->addChild('USR', $USR);
        $xml->addChild('PWD', $PASSWD);
        $xml->addChild('EMAIL', $EMAIL);
        $xml->addChild('HTMLEDITOR', $HTMLEDITOR);
        $xml->addChild('TIMEZONE', $TIMEZONE);
        $xml->addChild('LANG', $LANG);
        exec_action('settings-user');
        if (! XMLsave($xml, GSUSERSPATH . $file) ) {
            $error = i18n_r('CHMOD_ERROR');
        }
        
        # create website xml file
        createBak($wfile, GSDATAOTHERPATH, GSBACKUPSPATH.'other/');
        $xmls = new SimpleXMLExtended('<item></item>');
        $note = $xmls->addChild('SITENAME');
        $note->addCData($SITENAME);
        $note = $xmls->addChild('SITEURL');
        $note->addCData($SITEURL);
Reply
Thanks mikeh but I tested it in 3.0 and it still resetting the user to have all permissions if they click the save settings button on the settings page. Still not working in 3.0 even after adding the code in the settings.php.

Great work though other than that issue it works great. Sure wish we could figure that out. It seems to be over righting the xml permissions file each time the save button is hit? I have searched for a fix for this as well and cannot find one. If anybody knows how to fix this it would be great or am I missing something?
Reply
Maybe if we could just put a if statement in there that if not the main admin user it doesn't show the save button at all can that be done? I tested it that way by clicking the save button logged in as main admin and it doesn't change the other user settings but when you log in as the other users and click the save settings button it changes them back to full admin access? Seems if there was a way to just remove the save button for the other users it would work fine.
Reply
Hello Mikeh,

I would like to know if it's possible with your plugin to be more specific about permission in "categories" like page, files, template etc.
I ask this because i use the news manager and simple cache plugins, and i couldn't manage the permission with your great plugin.

i open a topic on this subject here (before i find your specific topic) http://get-simple.info/forum/topic/3149/...n-content/
Reply
Hello Mikey,

I've got the same problem in GS 3.0: after including exec_action('settings-user'); in settings.php, it still overwrites the multi-user settings. And even if the settings aren't overwritten, the next problem for the user will be how to change his/her password back to a normal one again... Can you help me?

Cheers, Alex
Reply
Hello, and first - thanks for a great plugin!

I am experiencing issue with it: if I disable "Support" tab, I get a "no" on the top of the browser.
I've tested it with all current browsers, and it is the same.

This is the code:

Code:
<style>
    .invalid {
      color: #D94136;
      font-size: 11px;
      font-weight: normal;
    }
  </style>
[b]  no[/b]<style type="text/css">.settings {display:none !important;}.plugins {display:none !important;}.support {display:none !important;}.theme {display:none !important;}</style><script type="text/javascript">

Can you please take a look at it? I've tested a new installation, and the same happens.

On GS 3.0 and Multi User v1.4.

I've also noticed that something is wrong with cookies, often logging out logging in doesn't work as it should. I log out the user with reduced privileges, and and than log in with full-privileged user, but the system logs in a restricted user.
Reply
It seems that there is a cookie problem. Cookies deleted, and it works.
Not a solution, tho.
Reply
minor issue

Code:
v1.4 line 708
echo $this->mmUserFile('SETTINGS');

looks like left-in debugging

It puts "no" at the top of my screen right after the body tag.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply




Users browsing this thread: 1 Guest(s)