Jump to content

PHP get url from form


spears47

Recommended Posts

Hello, I would appreciate if somebody could help me solve my problem

 

I have a form that posts to a php. what i want to do is from that form not get directed to the php but simply grab the url of where it goes. is this possible? for example

 

I hit submit on the form it POSTs to target.php where target.php then sends me to end.php

 

is there a way i can just grab the url from end.php without getting redirected?

Link to comment
https://forums.phpfreaks.com/topic/228224-php-get-url-from-form/
Share on other sites

I'm probably going to need to see a little coding example as I'm not 100% sure on what you are looking for.  I can tell you that likely you want your form to "post" to one .php page but actually "go" to another??

 

If that is the case then try php curl to post something "in the background" or combine the pages together via an include statement.

Okay thanks.  Here is the starting point

 

<html>
<form action='login_user.php' method='post'>
<input type="hidden" name="action" value="001" />
<input type="hidden" name="serverid" value="" />
USERNAME<input type='text' name='value1' size='20' maxlength='20'/>
PASSWORD<input type="password" name="value2" size="20" maxlength="32"/>
<input type="submit" value="login" name="login"/>
</form>
</html>

 

From there it goes to login_user.php with the post.  login_user.php then redirects to the account info page

 

What i want is the url from the account info page. is that possible?

From there it goes to login_user.php with the post.  login_user.php then redirects to the account info page

 

What i want is the url from the account info page. is that possible?

Where exactly do you "want" this url from the account info page and how are you going to use it?

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.