• Resolved wpexplorer

    (@wpexplorer)


    My Total theme has options to customize the Login page design but the actions aren’t added unless is_login() returns true to prevent registering action hooks when not needed. However, in your plugin you can set a custom login page and so is_login() will return false.

    I see you have a static method “AIOWPSecurity_Process_Renamed_Login_Page::is_renamed_login_page_requested” which can be used as an alternative to is_login() – however, this method requires passing the login slug so even in your own plugin code anywhere you use the function you have to pass on the slug. But it’s always going to be the same value for $login_slug

    Any chance you would update your static method so you don’t have to pass on the $login_slug and if you don’t then the plugin does it for you? This way you can optimize a couple places in your code where you use the static method and makes it easier for 3rd party integrations.

    Example of the updated code:

    Thank you for considering!

    • AJ
Viewing 1 replies (of 1 total)
  • Plugin Support hjogiupdraftplus

    (@hjogiupdraftplus)

    Hi @wpexplorer,

    global $pagenow will be still wp-login.php as per AIO_WP_Security set_pagenow_for_renamed_loginpage can you check is it for a login page?

    It might be helpful with other plugins which support hide login page.

    Thank for your suggesion, I will create internal ticket for this code improvement.

    Regards

Viewing 1 replies (of 1 total)
  • The topic ‘is_renamed_login_page_requested() optimization request’ is closed to new replies.