Forum Moderators: open

Message Too Old, No Replies

Form to Select Links

Seems simple but answer escapes me!

         

bumpaw

8:56 pm on Oct 24, 2004 (gmt 0)

10+ Year Member



I am working for a realtor trying to simplify his listings search with some predetermined saved searches. We would like to select from 6 zones in a list and 3 price ranges in a drop down, and then on submit yield a saved search URL from the big MLS search engine. The downside is that the owner wants his secretary to be able to update via Front Page.

Can javascript take two form fields and combine the values to yield on submit a predetermined URL?

adni18

12:21 pm on Oct 25, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Maybe one of these two links will help:

[javascript.internet.com...]

[javascript.internet.com...]

bumpaw

2:36 pm on Oct 25, 2004 (gmt 0)

10+ Year Member



Thanks, but those scripts don't work for what I'm doing. They allow the user to build the url with javascript, but I have no control of the url as it's saved in a database. I'm thinking that I'll have to do it with a script on the server.

adni18

8:33 pm on Oct 26, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



how about something like this:


<input type=text id=a><input type=text id=b><input type=submit onClick="window.location=document.all.a.value+document.all.b.value+'.html'">

Please explain in better detail if this is not what you are looking for.

bumpaw

9:21 pm on Oct 26, 2004 (gmt 0)

10+ Year Member



We are allowed to do searches and save the URL in their database. We have no control over the third party database and the URLs differ only in an id number. The javascript solutions seem to build the url ("a+b+.html" yields www.example.com/ab.html) and we can't do that here.

adni18

2:09 am on Oct 27, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



then give an example of a third-party selection and the destination URL you would like the person to be forwarded to, please. (Because I am still not sure what you wish to accomplish.)

bumpaw

4:52 am on Oct 27, 2004 (gmt 0)

10+ Year Member



example.com/property_search_results.asp?gateway_lo_code=L000915&amp;SavedSearchID=50602

I'll have maybe 30 links like this and the only difference is the last 6 digets.

adni18

12:19 pm on Oct 27, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



so you want to have a user select from a combo-box the last six digits in gateway_lo_code?

(The user selected a 123456:)

example.com/property_search_results.asp?gateway_lo_code=L123456&amp;SavedSearchID=50602

adni18

12:25 pm on Oct 27, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I again recommend this site. Look more carefully at its results. [javascript.internet.com...]