scott_yamahata@hotmail.co Posted January 30, 2009 Share Posted January 30, 2009 Not sure if this is a PHP issue or a MySQL one.Think this is a simple solution.In terms of my browse.php, I understand that I'm pulling information based on:<FORM name=browse action="browse.php" method=GET><SELECT NAME="id"> I also know that the id information is what's bringing back categories like "Architects" and "Carpentry." <OPTION VALUE="107">Architects</OPTION> <OPTION VALUE="94">Carpentry</OPTION> For example, this brings back all of the information under "Architects" and "Carpentry."Is there any way to refine the data even further?Say, for example, I wanted all of the work from "Architects" to be from a specific city?Thanks if anyone can help out.--Scott <FORM name=browse action="browse.php" method=GET> <INPUT type=HIDDEN name=""> <FONT FACE=Tahoma,Verdana,Arial SIZE=1 COLOR=#666666>Browse </FONT> <SELECT NAME="id"> <OPTION VALUE="0"></OPTION> <OPTION VALUE="107">Architects</OPTION> <OPTION VALUE="94">Carpentry</OPTION>[/][/] Quote Link to comment https://forums.phpfreaks.com/topic/143136-php-filtering/ Share on other sites More sharing options...
ngreenwood6 Posted January 30, 2009 Share Posted January 30, 2009 Welcome to the forums. First off you should really use code tags to wrap your code so that it is easier to read. Secondly, I am not quiet sure what you mean by your question, can you clarify? Quote Link to comment https://forums.phpfreaks.com/topic/143136-php-filtering/#findComment-750652 Share on other sites More sharing options...
premiso Posted January 30, 2009 Share Posted January 30, 2009 To help you provide us with more information. How would grab the specific city? Is it part of the form, as I do not see that there. This is probably both PHP and MySQL. To limit a MySQL query even further use the AND keyword in the WHERE clause: WHERE type = 'Architects' AND city = 'My City' That is a rough example, you will have to replace it with your code. Be more descriptive and you might get a more descriptive answer. Quote Link to comment https://forums.phpfreaks.com/topic/143136-php-filtering/#findComment-750657 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.