close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

MySQLi search form with additional parameter

Thread began 8/18/2014 12:36 pm by Jason | Last modified 8/19/2014 11:27 am by Jason Byrnes | 525 views | 5 replies |

Jason

MySQLi search form with additional parameter

I have a search page that is working correctly (kids_shift_search1.php, attached), but I needed to add an additional search parameter (event) to it. So far it's been unsuccessful. Something seems to be limiting my results to 1, but I cannot figure out what it is. The current page is attached also (kids_shift_search.php).

Attached Files
kids_shift_search.php
kids_shift_search1.php
Sign in to reply to this post

Jason ByrnesWebAssist

all of the peramiters are set to Integer.

Edit the recordset, and edit each variable, make sure the type is set to integer and the comma separated list option is checked.

Sign in to reply to this post

Jason

Checking the comma seperated list boxes fixed it! Thanks!

How can I change the query so that the first option would be "Show All" and it would return any result from that list?

Sign in to reply to this post

Jason ByrnesWebAssist

add an option with a blank value:

<option value="">show all</option>

and in the recordset SQL edit the condition to use a second OR comparison for -1 = newPerameter.

for example, you curently have the condition in the SQL for:
kids_program_time.id IN (WAQB_Param1)

and the WAQB_Param1 variable has the run time value set to use the time URL variable

adit the SQL To:
(kids_program_time.id IN (WAQB_Param1) OR -1 = WAQB_Param1_2)


then create another varaiable using the same settings as WAQB_Param1 variable but named WAQB_Param1_2, in the WAQB_Param1_2 variable, don't check the Comma separated list option.

Sign in to reply to this post

Jason

Perfect!
I suppose I can do the same thing for a "none" value in each column by setting the parameter value to "null" or "0" whichever the database default is?

Sign in to reply to this post

Jason ByrnesWebAssist

yes, that is correct.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...