Jump to content

redirect back to original page


ryanmetzler3

Recommended Posts

I have a comment section on my website. It requires your name, email, and comment. You can opt to login and then you do not have to fill in your name and email. My form looks like this: 

<tr>
   <td><label for="name">Name:</label></td>
   <input type="submit" id="loginbtn" value="Or Login" onclick="window.location='/login_scripts/login.php'" /></td>
</tr>
<tr>
   <td><label for="name">Email:</label></td>
   <td><input type="email" name="email" id='email'/></td>
</tr>

Once you login, the name and email fields disappear and you can just comment. I grab your user name from the database and insert that as your comment name. Anyways, how can I redirect them back to the comment section after they have been logged in? assuming they arrived at the login page from this specific login button...

Link to comment
https://forums.phpfreaks.com/topic/285455-redirect-back-to-original-page/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.