Home Forums WoodMart support forum Change the registration url to it's own page?

Change the registration url to it's own page?

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #183695

    vsupplier
    Participant

    So when someone clicks Login/Register on my menu, it opens up Image #1. When someone clicks “Create an account” it takes them to “website/my-account/?action=register”, however, I want my registration page on http://www.mywebsite.com/registration

    Image #1

    null

    #183725

    Artem Temos
    Keymaster

    Hello,

    WooCommerce has login and registration page on the same page by default. This form is developed for the WooCommerce login and registration page.

    Kind Regards

    #184391

    vsupplier
    Participant

    Yes but I am using a third party registration plugin and I have disabled the ability to create a new user in the “My Account” page. All I want is the link that says “CREATE AN ACCOUNT” to link to http://www.mywebsite.com/registration.

    I made a whole new registration page using registrationmagic and want to link to that page. I could remove this button and add 2 new ones in the menu, but I would rather keep this as it looks very nice (I just need the CREATE AN ACCOUNT link to go somewhere else)

    The HTML for the button shows

    a href=”http://mywebsite/my-account/?action=register”>Create an Account

    I would like to change that URL to mywebsite.com/registration

    After more analysis, I need to change this in the “Login Form Dropdown” sidebar menu.

    #184457

    Artem Temos
    Keymaster

    If you need to customize it, you can find the source code in the file /inc/integrations/woocommerce/template-tags.php. Related PHP functions are woodmart_sidebar_login_form and woodmart_login_form

    #185259

    vsupplier
    Participant

    I found the applicable code, but i’m not sure exactly what to change so I can set my own URL instead of it redirecting to the “My account” login page.

    #185295

    Artem Temos
    Keymaster

    You need to find the following line and replace href="" attribute with your own link

    <a href="<?php echo esc_url( add_query_arg( 'action', 'register', $account_link ) ); ?>" class="btn btn-style-link btn-color-primary create-account-button"><?php esc_html_e( 'Create an Account', 'woodmart' ); ?></a>

    #185481

    vsupplier
    Participant

    Worked perfectly, thanks!

    #185483

    Artem Temos
    Keymaster

    You are welcome.

Viewing 8 posts - 1 through 8 (of 8 total)

The topic ‘Change the registration url to it's own page?’ is closed to new replies.