Info
- 2 posts
- 2 voices
- Started 5 years ago by altmejd
- Latest reply from fel64
- This topic is not resolved
login form wordpress
-
- Posted 5 years ago #
At my site I have a login form put in the header (generated by wordpress, with wordpress functions) that displays either the form for the user to login or the welcome text with the username etc.
The reason I don't want to use wordpress own login function is because that forwards the user to their wordpress profile which they shouldn't be using.
The problem I now encountered using the usernames_i18n_fix.php plugin is that wordpress doesn't display the usernames properly. For the time being I've removed the username from the welcome text. But is there any way to make this work through wordpress without including bbpress every time wp loads?Is it possible somehow to redirect the user to the page they logged in from instead of sending them back to the forum main page?
To echo the username I use
<?php $user = wp_get_current_user(); echo $user->display_name; ?> -
- Posted 5 years ago #
To change where the user is redirected, add a hidden field to the login form called
redirect_to, with a value of where-ever you want the user to end up (default is in the dashboard). -
You must log in to post.