Displays login and/or registration forms.
This extension provide three main features:
- A login form to replace the WordPress login screen
- A registration form to replace the WordPress registration screen
- Redirects users away from the WordPress admin dashboard
By default, with no options, if the user is not logged in, this shortcode will show a login form and button for registration, and forgotten password. If logged in, a log out button will be shown.
Along with a lot of options for this shortcode, these can be disabled so that you can have a seperate login and registration page.
As with other shortcodes, WP Symposium Pro will use the theme styles so it matches your site.
The registration form can also tie into WP Symposium Pro, asking new users to complete additional Profile Extension fields.
Redirecting users from the admin dashboard
On most websites, it’s unlikely that you will want to allow your users to access the WordPress admin dashboard. Although there is nothing they can do, as they will probably be in the “subscriber” role, it’s a potential security risk and (probably more applicable) something you just don’t want to expose your users to.
Via WPS Pro->Setup->Login and Register, you can set the WordPress roles that are allowed to access the admin dashboard. Administrators will always have access.
Once you have ticked, and saved your choice, any users not in those ticked roles will be redirected to your site’s home page if they try to access the WordPress admin dashboard.
Setting a Registration Code
To support events (for example) you may give users a code they have to enter on registration.
You can set this up via WPS Pro->Setup->Login & Register. If you are looking at the Shortcodes page, a button will take you there to enter the code. It is not used as a shortcode option for security reasons, as the code could be viewed by simply looking at the web page source.
Redirect from profile/forums
You can add the login_url option to [wps-activity] and [wps-forum] shortcodes to allow a user to login and return back to the page.
Provided in the Core Plugin.
You can use the global shortcode settings via WPS Pro->Shortcodes in the admin dashboard, or add them to the shortcode as options.
To add a login form to a WordPress page, setting the URL that the user goes to after logging in to /profile, you would add the following:
Or, to disable the registration button (you might have this on your menu or elsewhere) and the CAPTCHA code:
[wps-login-form register="0" captcha="0"]
For registration, the following will display the registration form by default, the Town/City and Country fields mandatory, and change the mandatory text to a blue “required”:
[wps-login-form mode="register" town="*Town/City" country="*Country" mandatory="<span style='color:blue;'> required</span>"]
I would not recommend allowing users to set their own password, unless your site is in a secure environment, otherwise you are opening up your site to automated (spam) registrations.
The following (which shows default values and an example of using the shortcode option) can be set via the admin dashboard (WPS Pro->Shortcodes) or added as options to the shortcode in your WordPress page, post or widget.
|Show forgotten password||(lostpassword=”1″)|
|URL to go to after logging in||(url=”http://localhost”)|
|Login label||(label_login=”Log In”)|
|Email address label||(label_email=”Email address”)|
|Remember me label||(label_remember_me=”Remember me”)|
|Forgotten password label||(label_lostpassword=”Forgotten password?”)|
|URL to go to after logging out||(url_logout=”http://localhost”)|
|Back to login label||(label_back_to_login=”Back to login”)|
|Include display name||(display_name=”0″)|
|Display name label||(label_display_name=”Display name as shown on this site”)|
|Confirm email label||(label_email_confirm=”Re-enter email address”)|
|Include full name||(name=”1″)|
|First and family name label||(label_name=”Your first name and family name”)|
|Registration code label||(registration_code=”Registration code”)|
|Registration code (for above)||Setup via WPS Pro->Setup|
|Password sent text||(text_register_prompt=”A password will be sent to the email address you enter.”)|
|Redirection URL after registration||(registration_url=””)|
|Let users set password||(password=”0″)|
|Re-enter password label||(label_password_confirm=”Re-enter password”)|
|Mandatory suffix||(mandatory=” *”)|
|Instructions||(text_lostpassword_prompt=”Enter your username or email address, and a new password will be sent to you. You can then login and change it on the Edit Profile page.”)|
|Username/email not found text||(text_username_not_found=”Username or email address (%s) not found.”)|
|New password message||(text_new_password=”Your new password is: %s”)|
|Login URL (in password reminder email)||(text_login_url=”[current page]”)|
|Password reset message||(text_password_reset=”Your password has been reset and sent to the email address of the account.
Please check your email in a few minutes, including the spam folder. You can then login and change it on the Edit Profile page.”)
|Account is closed message||(text_password_closed=”This account was closed on %s at %s.”)|
|Send new password label||(label_lostpassword_send=”Send new password”)|