Jump to content

Recommended Posts

Greetings to All, New guy here looking for a little assistance.

 

Please visit my website (http://www.justvideod.net) and if you look in the top right corner you will see what I'm trying to do. I want to add a single input box with a submit button.

 

When a visitor enters a number in the input box, I want to append that number to my URL and redirect them to the appropriate page.

 

For example, www.justvideod.net/branded/497710. I want the visitor to be able to enter their tour MLS number (497710 in this example) and after pressing Submit be redirected to that page.

 

Any help or suggestions on how to do this is greatly appreciated!

 

Link to comment
https://forums.phpfreaks.com/topic/171651-form-redirect-help/
Share on other sites

thats easy . you just to put the name tag to your imput like this

<form ...>

<input name="number" type="text" />

<input type="submit" value="submit" />

</form>

 

then with your php code catch some action you can put it on your form action an with a if check the action then get the variable name with post or get whatever ... do the next step  ;)

Link to comment
https://forums.phpfreaks.com/topic/171651-form-redirect-help/#findComment-905127
Share on other sites

Thanks for the quick reply but I'm not that technical...I added some simple code to my page:

 

<form method='get' action='http://www.justvideod.net/branded/'>

<input type='hidden' name='' value=''>

<input type='text' name='id'>

<input type='submit'>

</form>

 

This almost works! LOL!  But I can't get rid of the ?id=

 

The resulting url is www.justvideod.net/branded/?id=497710

 

and I just want www.justvideod.net/branded/497710

 

 

Link to comment
https://forums.phpfreaks.com/topic/171651-form-redirect-help/#findComment-905224
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.