Tagged: member login
-
AuthorPosts
-
June 17, 2013 at 4:44 am #24914
Hi Guys,
I would like to know, how would I accomplish this:
I would like to remove the search icon in menu bar and implement a member login in place of the search icon (or if possible in the header area). How would I do that and what nice plugin to use for a membership log in ?
Please help.
Regards,
Gurmit
June 17, 2013 at 6:08 am #125164Open up functions-enfold.php and replace:
$items .= '<li id="menu-item-search" class="noMobile menu-item menu-item-search-dropdown"><a href="?s=" data-avia-search-tooltip="'.$form.'">'.$avia_config['font_icons']['search'].'</a></li>';
with
if(is_user_logged_in())
{
$items .= '<li><a title="'.__('Logout','avia_framework').'" href="'. wp_logout_url(get_permalink()) .'">'.__('Logout','avia_framework').'</a></li>';
}
else
{
$items .= '<li><a title="'.__('Login','avia_framework').'" href="'. wp_login_url(get_permalink()) .'">'.__('Login','avia_framework').'</a></li>';
}This will add a login link to the menu if the user is not logged in and a log out link to the menu if the user is logged in.
June 17, 2013 at 10:43 am #125165Hi Dude,
I did as what you’ve instructed. However, my website crashed. I am getting this error: Parse error: syntax error, unexpected ‘=’ in /home/bestmort/public_html/wp-content/themes/enfold_old/functions-enfold.php on line 42
Is there a way I can revert it back to its original? I am sorry I am new to this.
Please help.
Best regard,
Gurmit
June 17, 2013 at 1:15 pm #125166Hey!
I corrected the code – it should work now.
Regards,
Peter
June 18, 2013 at 12:19 am #125167HI Peter,
I’m still working on getting my website back as I can no longer access it.
June 18, 2013 at 12:40 am #125168Hi Peter,
I am able to restore my website now. Is there any other way to achieve the member log in without touching the function.php?
Best regard,
Gurmit
June 18, 2013 at 2:07 am #125169Hi Peter,
Thank you for the help, the login is now in place. I would like to ask few more assistance:
I would like to add a button for Trainings in the login areas. How would I implement that?
Best regard,
Gurmit
June 18, 2013 at 2:24 am #125170Hi Guys,
When I clicked on the login it redirected me to WordPress Login area. I would like to implement something like the REGISTER/LOGIN in this site: http://www.nontypicalbuck.com/
Afterwhich, when a member is already logged in I need a button for Trainings within that page. How to implement?
Please help.
Best regard,
Gurmit
June 18, 2013 at 5:32 am #125171Hey!
1) This login page is part of the WooCommerce plugin – you just need to link to the “My account” page (you can use the menu manager (Appearance > Menu) to add it to the menu.
2) You can try to add the html code of the button to the “My Account” page, if this doesn’t work you need to add the html code to the account page template ( wp-contentpluginswoocommercetemplatesmyaccountmy-account.php ).
Regards,
Peter
June 19, 2013 at 12:30 am #125172Hi Peter,
Is this the WooCommerce plugin you’re referring to? “WooCommerce – excelling eCommerce”
Best regards,
Gurmit
June 19, 2013 at 1:42 am #125173Hi Peter,
I’ve read the documentation of WooCommerce. In it says Registration and Customer Account which are both so important. but in my settings there is no registration / customer account. Do I need to purchase a premium version before I can actually implement this? Please advise.
Best regards,
Gurmit
June 19, 2013 at 1:52 am #125174Hi Peter,
Oooops, I see it now. But I need to know, do I have to set up My Account page manually or does it come with the installation of the plugin?
Best regards,
Gurmit
June 19, 2013 at 5:39 am #125175Hey!
WooCommerce comes with a “setup assistant” – it will create all necessary pages automatically. If you don’t want to use the setup assistant insert following shortcode into a page
[woocommerce_my_account]
Best regards,
Peter
June 20, 2013 at 12:24 am #125176Hi Peter,
I already set up the necessary pages. However, when I use the permalink of My Account to link it with the word “Register”, it always points out to 404 page. At the same time, I couldn’t get the register page. I’m lost.
Best regards,
Richard
June 21, 2013 at 7:38 pm #125177I’m not sure why it’s not working because the account page seems to work for me: http://bestmortgagebrokers.net/my-account/ – just go to Appearance > Menus and add the “My account” page to the menu. If this doesn’t work try to use the custom link option and insert the account page url into the link field. The “My account” page displays the “register” form and the “login” form.
-
AuthorPosts
- The topic ‘member login in menu bar area’ is closed to new replies.