CodeIgniter Forums

Full Version: Site Search using CI
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]codelearn[/eluser]
Hey all,

I am trying to build search capability for a certain feature on my site.

There is a business directory, and I'd like to add the ability for users to search the directory for a certain store. Obviously the point would be to not force the user to match a name exactly, and "close" querys would return the correct result.

Where would be a good place to start?

Thanks!

El Forum

[eluser]NateL[/eluser]
>:-( Where was this website when I was in college? I really needed it. :-P

aside from that... x2 on your need for a search. I was going to start a new thread on the same topic one of these days Smile

El Forum

[eluser]phantom-a[/eluser]
You want to search the database using the "like" method.

Maby this tutorial might help you. It follow what your after, maby not exactly what you need but it covers a bit about it.
http://video.derekallard.com/application

But if your allowing user to search the database with like method your best off to put a limiti on characters, some searches put a limit of 3 characters or else they could 1 letter like "a" and hit search and it will pull out the whole part of your database you told it search in. :-)