Support Forum › Forums › Stationero – WooCommerce Stationery WordPress theme › user registration
- This topic has 3 replies, 2 voices, and was last updated 8 months ago by PrestaBrain.
-
AuthorPosts
-
March 25, 2024 at 2:20 am #4573leliorapidaSupport Expired
Hi, on the stationero theme everything works fine, on woocommerce I activated the function everyone can register but when I click on the register item from the menu above, it takes me to an error page. If we can solve the problem then I would like to know how I can change the user registration page
March 25, 2024 at 8:57 am #4574Dear mate,
You want click “create an account” to link my account page.
Please use the child theme then add code below in the functions.php file of the child theme.
if (!function_exists('stationero_form_login')) { function stationero_form_login() { if (stationero_is_woocommerce_activated()) { $registration_url = get_permalink(get_option('woocommerce_myaccount_page_id')); } else { $registration_url = wp_registration_url(); } ?> <div class="login-form-head"> <span class="login-form-title"><?php esc_attr_e('Sign in', 'stationero') ?></span> <span class="pull-right"> <a class="register-link" href="<?php echo get_permalink(get_option('woocommerce_myaccount_page_id')); ?>" title="<?php esc_attr_e('Register', 'stationero'); ?>"><?php esc_attr_e('Create an Account', 'stationero'); ?></a> </span> </div> <form class="stationero-login-form-ajax" data-toggle="validator"> <p> <label><?php esc_attr_e('Username or email', 'stationero'); ?> <span class="required">*</span></label> <input name="username" type="text" required placeholder="<?php esc_attr_e('Username', 'stationero') ?>"> </p> <p> <label><?php esc_attr_e('Password', 'stationero'); ?> <span class="required">*</span></label> <input name="password" type="password" required placeholder="<?php esc_attr_e('Password', 'stationero') ?>"> </p> <button type="submit" data-button-action class="btn btn-primary btn-block w-100 mt-1"><?php esc_html_e('Login', 'stationero') ?></button> <input type="hidden" name="action" value="stationero_login"> <?php wp_nonce_field('ajax-stationero-login-nonce', 'security-login'); ?> </form> <div class="login-form-bottom"> <a href="<?php echo wp_lostpassword_url(get_permalink()); ?>" class="lostpass-link" title="<?php esc_attr_e('Lost your password?', 'stationero'); ?>"><?php esc_attr_e('Lost your password?', 'stationero'); ?></a> </div> <?php } }
Choose Page My Account, Go to WooCommerce > Settings > Advanced.
To add this form, you need to install the WooCommerce plugin and go to WooCommerce->Settings of your dashboard. Click on the Privacy and Accounts section and check the option to the Allow customers to create an account on the “My Account” page option.
Thanks.
- This reply was modified 8 months ago by PrestaBrain.
- This reply was modified 8 months ago by PrestaBrain.
March 25, 2024 at 3:05 pm #4577leliorapidaSupport ExpiredHi, I followed the steps indicated, now when I connect to the site and click on login/register it takes me back to the screen shown in the photo, how do I modify the page with the links to have the customer fill out the form correctly?
March 26, 2024 at 1:53 pm #4578 -
AuthorPosts
You must be logged in to reply to this topic.