Database search question
| From: | Chris Payne | Date: | Sun, 31 Mar 2002 03:15:11 +0000 |
| Subject: | Database search question | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-18067@lists.php.net to get a copy of this message | ||
Hi there everyone,
How can I accomplish the following?
I have a table called search,
I have 3 fields, city, country, type
I also have an imput box where you can type in a search word. What I need is, say you type in
hotels germany, I need the search to break up the sentence and then search each 3 fields in the DB
looking for a match.
So, for example: it would find hotels in type and germany in country, see that they belong together
and then display those results - how can I do this?
I know I need to splitup my search phrase into individual words to search, but i'm stuck.
Thanks for any help.
Chris