Welcome Guest, Not a member yet? Register   Sign In
Multiple Keyword Search
#11

[eluser]rich.a.coy[/eluser]
Perfect Thanks!

I'm getting a PHP error because I'm looking for something that is included in the JOIN, that I have not added yet but other than that it seems to work as expected. Thanks again for your help!


[edit]
I've just realized that this will return to broad of a match set. If someone searches "Rich" and "Orlando" it will return all Rich's and all Orlando's, not just Rich's in Orlando.

This needs some way to say that ALL words must be present in a record.
[/edit]
#12

[eluser]Michael Wales[/eluser]
Look into Sphinx. Searching MySQL in the manner you are doing is inefficient at best.
#13

[eluser]rich.a.coy[/eluser]
Your probably right about this being inefficient however I'm developing on a shared box at the moment and don't have the ability to install a search script like Sphinx. I'll be moving onto a dedicated box before launch but need to develop this search functionality now.

I just noticed that Facebook has people search for new friends by name or email address only. Maybe I should limit it to that. If it's a valid email format search for that, if it's not explode the search string and compare the first part to first name and second part to last name. The only limitation is I'm allowing people to hide their first name and last name if they want so then they would not be findable.




Theme © iAndrew 2016 - Forum software by © MyBB