473,508 Members | 2,091 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Search by drop down list and checkbox

33 New Member
Hi. I want to create a search form using the drop down list and checkbox. First, the users have to select from drop down list whether they want to search by date or id. After that, for example, a new pair of drop down list will display for the users to choose the start date and end date. Second, the users have to check the checkbox to make sure what type of information that they want to filter. I have done the form for searching but I don't know How to do the searching script. All the data will be retrieved from MySQL database. Below is parts of the code. Thanks in advance for any help.

Expand|Select|Wrap|Line Numbers
  1. <td class="fontBold">Search By:</td>                    
  2. <td><select name="search" id="search" class="font" onChange="display(this, 'date', 'id');">
  3. <option value="">-- Please select --</option>
  4. <option value="date">Date</option>
  5. <option value="id">ID</option>
  6. </select>
  7. </td>
  8. </tr>
  9.  
Expand|Select|Wrap|Line Numbers
  1. <table width="1000" border="1" align="center">
  2. <tr>          
  3. <td class="fontBold">Filter:</td>
  4. <td><input type="checkbox" name="check_filter" id="check_filter" value="yes" onClick="check(document.search.check_list)">Check All</td>
  5. </tr>
  6. <tr>
  7. <td><input type="checkbox" name="check_list" id="no" value="1">No</td>
  8. <td><input type="checkbox" name="check_list" id="id" value="2">ID</td>
  9. <td><input type="checkbox" name="check_list" id="type" value="3">Type</td>
  10. <td><input type="checkbox" name="check_list" id="address" value="4">Address</td>
  11. </tr>
  12. <tr>
  13. <td><input type="checkbox" name="check_list" id="status" value="5">Status</td>
  14. <td><input type="checkbox" name="check_list" id="start_date" value="6">Start Date</td>
  15. <td><input type="checkbox" name="check_list" id="end_date" value="7">End Date</td>
  16. <td><input type="checkbox" name="check_list" id="amount" value="8">amount</td>
  17. </tr>
  18. //...
  19. //...
  20. //...others type of filter
  21. </table>
  22.  
Oct 18 '10 #1
0 1312

Sign in to post your reply or Sign up for a free account.

Similar topics

2
9446
by: kmnotes04 | last post by:
Is it possible to link one drop-down box to another? For example, if a name is chosen from a drop-down list, can another drop-down list then automatically display the person's office as a result of...
3
26258
by: Stephen Adam | last post by:
Hi there, I'm sure i'm missing something really simple here, all i want to do is get the value of the selected item in a list box. Even after much fiddling about last night I still could not get...
2
12595
by: Yoshitha | last post by:
hi I have 2 drop down lists in my application.1st list ontains itmes like java,jsp,swings,vb.net etc.2nd list contains percentage i.e it conatains the items like 50,60,70,80,90,100. i will...
4
2116
by: Rudy | last post by:
Hello! I have 4 diffrent drop downlist. I want a user to select a value from a drop down list, and place it in a SELECT statement. How would I put that value in the select statement. And if the...
0
1502
by: thebison | last post by:
Hi all, I hope someone can help with this relatively simple problem. I am building a timesheet application using ASP.NET C# with Visual Studio 2003.As it is only a protoype application, my...
3
6871
by: Yi Chen | last post by:
We have a drop down list on a PHP page, with several product names, and when people click one item, we will refresh the same page with the product name as parameter, and in turn we want to include...
8
10165
by: cptuser | last post by:
Hi, I've put together this javascript taken from various sources, but i think it is wrong or missing something. If particular options are selected within a drop down menu, then the check botton...
1
1880
by: Luke Sayaw | last post by:
Hi All, I wonder how do I include a checkbox in a dropdownlist control.? I am working on a particular enhancement for the web application. In the application, the user can do a search based on...
2
3190
by: leeperman | last post by:
In Dreaweaver I cannot filter my database results to display only specific data that is retrieved from mulptile drop down list on my search page. The drop down list selections are posted to my...
2
3443
by: ndeeley | last post by:
Hello, I've written a script which returns the admin rights of users in a table - their access level, and their priviledges. The priviledge are returned to a check box and the admin rights to a...
0
7225
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7124
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7326
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
7046
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5629
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5053
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4707
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3195
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1558
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.