The user chooses from a dropdown menu then clicks submit.
The target page shows only the records containing what was chosen from the list.
What I would like is to allow the user to choose multiple items from the
list while holding down the ctrl key, then filter the search results based on what was chosen.
Can you tell me how to change the syntax on my target page query so that is allows multiple input.
something like -
WHERE titles.level_id IN (1,2,3,4)
This is the current query
Expand|Select|Wrap|Line Numbers
- $query_rsTitles = "SELECT id, title, company, `description`, resources, location, url, image, keyword, copies FROM titles WHERE titles.level_id = ". GetSQLValueString($_POST['softwareLevel'], "int") ." ORDER BY id ASC";
Expand|Select|Wrap|Line Numbers
- <select name="softwareLevel[]" id="softwareLevel">
- <?php
- do {
- ?>
- <option value="<?php echo $row_rs_level['level_id']?>"><?php echo $row_rs_level['level']?></option>
- <?php
- } while ($row_rs_level = mysql_fetch_assoc($rs_level));
- $rows = mysql_num_rows($rs_level);
- if($rows > 0) {
- mysql_data_seek($rs_level, 0);
- $row_rs_level = mysql_fetch_assoc($rs_level);
- }
- ?>
- </select>