Results 1 to 5 of 5
  1. #1
    Join Date
    Mar 2009
    Posts
    30
    Plugin Contributions
    0

    Default Why admin_level sets to '0' when creating new admins?

    Why after saving an admin enty its admin_level sets to '0'?

    i do not see admin_level submitted by the form (it is kind of commented out)

    thanks

    Calixto

  2. #2
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Why admin_level sets to '0' when creating new admins?

    That's because the admin-demo feature is presently disabled in the software.
    In a future version there will be full admin security, allowing different permissions for different users. Until then, the demo option is disabled.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Mar 2009
    Posts
    30
    Plugin Contributions
    0

    Default Re: Why admin_level sets to '0' when creating new admins?

    Quote Originally Posted by DrByte View Post
    That's because the admin-demo feature is presently disabled in the software.
    In a future version there will be full admin security, allowing different permissions for different users. Until then, the demo option is disabled.

    I must be missing something very obvious, so I apologize.
    Admin level = 0 stands for the no used Demo user.
    My point is that while going into editing the admin list, and saving the result, zencart sets the admin_level to zero, which should not be done.
    My poor PHP knowledge indicates that admin_level is not submited to the reloaded page, so the 'case save: option', having not received admin_level via POST, sets it to zero

    look,
    $admin_level = zen_db_prepare_input($_POST['admin_level']);
    I added this line to force one
    $admin_level = 1;

    check edit_admin form code. In 1.3.8 admin_level is not posted

  4. #4
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Why admin_level sets to '0' when creating new admins?

    The admin_level field is not used in v1.3.8. Thus whether the value in the database for each user's admin_level is set to a 0 or a 1 doesn't make any difference.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Mar 2009
    Posts
    30
    Plugin Contributions
    0

    Default Re: Why admin_level sets to '0' when creating new admins?

    thank you

 

 

Similar Threads

  1. Error when creating new account
    By sinsor in forum Managing Customers and Orders
    Replies: 1
    Last Post: 17 Nov 2009, 10:14 PM
  2. Error when creating new accounts
    By hencore in forum General Questions
    Replies: 2
    Last Post: 31 Mar 2008, 03:17 PM
  3. Creating 'product sets'?
    By Hammtech in forum Setting Up Categories, Products, Attributes
    Replies: 6
    Last Post: 5 Dec 2006, 09:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR