• Hi,

    I hope this is an easy question to answer. I am currently themeing my wordpress login page. However, there are some conditional statements I’d like to use for headers and such that I can’t figure out.

    For example, my login url is: https://sitename.com/login/ (this is using a page template called login.php)

    However, when a user clicks on register, it takes them to: https://sitename.com/login/?action=register

    My question is if there is a wordpress conditional statement to only target the register page? I am using is_page(‘login’) for my first login url, but can’t figure out how to target my register page.

    Any help would be appreciated, thanks in advance!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter ranji77

    (@ranji77)

    bump, please anyone know?

    Thread Starter ranji77

    (@ranji77)

    last bump, promise…really hoping someone would know this though.

    I think there is one solution. But I am not sure whether it will work or not. Since only some of the people face this problem, there are no more posts on this and many of them don’t know how to resolve the problem.

    My idea is:-

    1) Open your Website Cpanel (Not the Admin panel)
    2) Under Domains, click redirects
    3) And create a redirect from https://sitename.com/login/?action=register to https://sitename.com/login.

    So whenever, a user clicks on register link, it will automatically redirect to https://sitename.com/login where they can login or register.

    Hope this helped you!

    Thread Starter ranji77

    (@ranji77)

    Thanks Thejas, but I don’t want to redirect my register page to the normal login page. I’m just looking to do some conditional statements so I can change the title headers from “Login” to “Register”. Since they are both technically using the login.php template I have created, I can’t differentiate between the two.

    Yes, you can edit wp-login.php and paste in a different folder where you can edit all the headers. By doing this, the changes you have made won’t reset when you upgrade!

    Thanks:)

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Conditional statement for register page’ is closed to new replies.