Search Form

2 posts by 2 authors in: Forums > CMS Builder
Last Post: October 4, 2010   (RSS)

By KCMedia - October 3, 2010

Hi

I am having some problems trying to get a search form for a website to work.

I want to have a search for people to use on the pre owned bikes section.

I have created a form attached or here http://actionmc.com.au/used-motorcyclesSearch.php and below that you will see the brands lsited but i want to be able to have people search these fields.

style "dropdown" it is a list viewer in the DB
makes "drop down" with all the makes of bikes
keywords "general words"
price from price to "i guess it needs search prices in the db"

I really need some help with this it is doing my head in.

i have attached the files.

thanks

Craig
Thanks



Craig

KC Media Solutions

www.kcmedia.biz

Re: [kcmedia] Search Form

By Jason - October 4, 2010

Hi Craig,

A couple things I noticed. First, you're style dropdown is populated with blank information. You're filling this with the "style" field from the used_motorcycles table. There doesn't seem to be any information in this field. Make sure you're using the correct field name.

Second, your form is submitting to cmsAdmin/lib/list_viewer.php, not used_motorcycles.php, you may want to change this.

Finally, on used_motorcycles.php your where clause is only taking information from the manufacturer form field. If the names of all your form fields match the names of the fields in motorcycle_history (I'm assuming this is the table you want to be searching), then you can get the function to do the where clause automatically by making 'allowSearch' => 1,

Hope this gets you started. Let me know if you have any other questions.
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/