Hi there Basically I've got a search form on my website www(.)fetch-boy(.)com, which is: <input type=text name=q size=50 value=""> and a link further down the page linking to another site which has a search facility. What I need to do is when a user has entered a search phrase in the search box, and is taken to the results page (which is still on my site), I want the other link that I mentioned above to somehow call what their search-phrase was, so it is part of the url i.e. www.the other website with a search box.com/?q=search phrase. So basically the search box on that site is prefilled with the search phrase they used on my site. I think it's probably to do with "q", but I don't know what html I'd use to incorporate it in the url, but I expect it's simple lol. Hope this all makes sense, and thanks in advance for any help
If I understand your question on how to dynamically put their search phrase into the destination url, I don't believe you can do this with HTML. You'd have to use a server side script like php, asp, cold fusion, or even javascript can do it. Are you familiar with any other coding languages and will your server support any of these?
Yes you would have to use a server side script such as php to do this. It is pretty simple to implement if your site is already dynamicly driven.
Thanks for the help guys. I think maybe I wasn't clear enough on it. To make it clearer (I hope), basically I want to take a search phrase that someone has searched for, and make it appear elsewhere on the page. For instance, much like a search engine - when you've typed in the phrase you're searching for, the next page says "Your search phrase ***** returned x results". I want to know how to get the ***** part to show in a separate part of text on a page. Thanks again
One way of doing it with PHP would be the following: In the first page add a form with a simple input field: <form method="POST" action="Page2.htm"> <input type="text" name="Keyword"> <input type="submit"> </form> Code (markup): Then on page2 (where ever you want the keyword to be shown) ad this: <?php if (isset($_POST['Keyword']) && $_POST['Keyword'] != '') { echo $_POST['Keyword']; } ?> Code (markup): The if statement helps to prevent a php code error when that variable has not been set. This can happen if some one goes directly to that page or does not use the form to get to that page. I haven't tested this code but it looks like it would work.