St.
St.

Reputation: 143

ajax search form for ColdFusion

I am looking for some technique like search form or form filter. This is a reference . It is a hotel finding website.

My question is here, how to use coldfusion to create this kind of searching form with ajax? Please give me some idea or tips , i will appreciate with you assist !

I have just get some idea on ajax search form with text.

<form>
 Search: <input type="text" name="search">
 <input type="button" value="Search">
 </form>

 <cfdiv bind="url:movieresults.cfm?search={search}">
 </cfdiv>

Upvotes: 1

Views: 377

Answers (1)

coldfusiondevshop
coldfusiondevshop

Reputation: 683

In general terms, a search form in CF has the same basic concept as a search form in any other format: you have a form wherein you allow the user to supply search criteria and you have some collection of data to search against. So, you see the actual search form itself is only but a small part of searching. You need to construct the data object you will search against and you need to build the pieces to add to that collection (if necessary) and maintain it. Tossing in the Ajax interface will only complicate matters so I'd recommend you stick with a basic search HTML form and once you've mastered submitting a search, doing the search through your data collection and returning that collection to the user in the form of a useful results page...only then should you consider modifying it to run with an Ajax engine.

A good place to start for how to work with cfindex and cfsearch (Coldfusion's tags that create the data collection and to search against that collection) would be found here.

Walking before running, grasshopper. If you encounter any specific problems, feel free to come back here and we'll see what we can do for you. In the meantime, check out our ColdFusion resources thread. It has a great many links to common CF resources that all CF devs, beginners to experts, need/use to help get the job done.

Upvotes: 1

Related Questions