Hey all,
I am having an issue with filtering price from a form variable so maybe someone can tell me how I'm screwing this up.
I have a search page that has 3 criterias for search - category 'cat', price 'price' and location 'area'. I am using Dreamweaver 8 for this project. I can create the query for both cat and area for the double filter, but when i get to price it removes all the records from view.
I removed the 2 working queries and am now focusing on the 'price' query. My SQL looks something like this:
SELECT Pcategory, Pprice, Paddress
FROM propertydata
WHERE ((Pprice = colname))
ORDER BY Pprice ASC
VARIABLE:
Name: colname
Type: Text
Default Value: -1
Runtime Value: $_POST['price']
Executing the search page returns all records with "$0" for a price (about 70) and thats all. No matter which price choice i use.
My form page that passes the variable is set up like this:
<select name="price" id="price">
<option value="BETWEEN 0 AND 100000">Under $100,000</option>
<option value="BETWEEN 100000 AND 200000">$100,000 - $200,000</option>
<option value="BETWEEN 200000 AND 300000" selected>$200,000 - $300,000</option>
<option value="BETWEEN 300000 AND 400000">$300,000 - $400,000</option>
<option value="BETWEEN 400000 AND 500000">$400,000 - $500,000</option>
...and so on.
And i if add another query to this equation like 'cat' nothing shows up...
If you need actual code let me know and i'll post. Can anyone tell my why this is coming up like this? I appreciate the help.