• Resolved euro11

    (@euro11)


    Hi. I password protected wp-admin directory using Directory Privacy on my cpanel. It pops up whenever I log in as a user on the WooCommerce users page (and it shouldn’t). it actually has no effect on the users page and I can simply cancel it and login as a user.

    How can I hide it for users ?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Saif

    (@babylon1999)

    Hello @euro11,

    Sorry, but I’m not sure if I’m getting the full picture here.

    Could you please provide more details and attach some screenshots to help understand what you’re trying to achieve?

    Feel free to use Snipboard to upload your screenshots.

    Look forward to hearing back from you.

    Thread Starter euro11

    (@euro11)

    Well I have no idea how else to explain. password protecting the wp-admin directory to add another layer of security is a common thing:

    https://www.wpbeginner.com/wp-tutorials/how-to-password-protect-your-wordpress-admin-wp-admin-directory/

    It’s supposed to protect the wp-admin directory ONLY for admins and not for users but it also protects the login page for users as well and once users try to log in, it pops up. since users don’t have access to that password, it makes no sense to be displayed to users, not to mention that it doesn’t affect the users login page at all and users can simply cancel it and log in as usual without it.

    So I was thinking maybe there was a rule for .htaccess or a code snippet to hide it for users.

    It’s also worth mentioning that it creates a separate .htaccess file in wp-admin folder when I password protect the wp-admin directory:

    AuthType Basic
    AuthName "Protected 'public_html/wp-admin'"
    AuthUserFile "/home/user/.htpasswds/public_html/wp-admin/passwd"
    Require valid-user

    Maybe adding a line to hide it for the users page might fix the issue.

    • This reply was modified 1 year, 7 months ago by euro11.
    • This reply was modified 1 year, 7 months ago by Jan Dembowski.
    Saif

    (@babylon1999)

    Thank you for the clarification!

    So if I understand this correctly, you’re trying to protect the wp-admin page with an additional authentication prompt, but you’re finding that the WooCommerce login page is also triggering the prompt.

    The WooCommerce login page is just a visually enhanced version of the wp-admin page. Meaning, you can still log in as an administrator from the WooCommerce page, so I don’t think excluding the page will be an effective option for what you’re trying to achieve.

    Since this is a fairly complex development topic, I’m going to leave it open for a bit to see if anyone is able to chime in to help you out.

    I suggest you check this guide for other options on how to secure your WooCommerce store.

    You can also visit the WooCommerce Facebook group or the #developers channel of the WooCommerce Community Slack. We’re lucky to have a great community of open-source developers for WooCommerce, and many of our developers hang out there, as well.

    Cheers!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How to hide password protected wp-admin login form from users page ?’ is closed to new replies.