We have a client website and a staff website both housed within WordPress. They asked me if it was possible to have a login box on the client side that would allow us to login to the staff website. I wrote a form on the client side that creates a login box. The form is functional because when you login it either redirects you to the staff site or the WordPress login of the staff site if you are not signed into the client site. Is there any way that I can make it so it just logs you in as opposed to redirecting you to the login page for the staff site? Here's the form that I wrote on the client site:
<form method="post" action="http://staff.writing.msu.edu/wp-admin" id="loginform" name="loginform">
<p>
<label for="user_login">Username<br>
<input type="text" size="20" value="" class="input" id="user_login" name="log"></label>
</p>
<p>
<label for="user_pass">Password<br>
<input type="password" size="20" value="" class="input" id="user_pass" name="pwd"></label>
</p>
<p class="forgetmenot"><label for="rememberme"><input type="checkbox" value="forever" id="rememberme" name="rememberme"> Remember Me</label></p>
<p class="submit">
<input type="submit" value="Log In" class="button button-primary button-large" id="wp-submit" name="wp-submit">
<input type="hidden" value="http://yourdomain.com/blog/wp-admin" name="redirect_to">
<input type="hidden" value="1" name="testcookie">
</p>