Welcome! Log In Create A New Profile

Advanced

[PHP] Mysql search

Posted by Ryan S 
Ryan S
[PHP] Mysql search
October 22, 2008 06:50AM
Hey all,
I have two columns in my DB
title varchar(254)
and
jtext text

which I would like to search, as the user might enter two or more words I am opting not to use LIKE %search_term% so started searching google, I came across this very promising class:
http://code.activestate.com/recipes/125901/

but when i tried to run it I am just getting a blank page, no errors or anything.

Am hoping someone out there can recommend a better script or maybe share some of your own code?

Any help would be appreciated.

Thanks,
Ryan

------
- The faulty interface lies between the chair and the keyboard.
- Creativity is great, but plagiarism is faster!
- Smile, everyone loves a moron. :-)





--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Robert Cummings
Re: [PHP] Mysql search
October 22, 2008 07:15AM
On Tue, 2008-10-21 at 21:48 -0700, Ryan S wrote:
> Hey all,
> I have two columns in my DB
> title varchar(254)
> and
> jtext text
>
> which I would like to search, as the user might enter two or more words I am opting not to use LIKE %search_term% so started searching google, I came across this very promising class:
> http://code.activestate.com/recipes/125901/
>
> but when i tried to run it I am just getting a blank page, no errors or anything.
>
> Am hoping someone out there can recommend a better script or maybe share some of your own code?
>
> Any help would be appreciated.

Do it right... read up on MySQL's fulltext matching.

Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Ryan S
Re: [PHP] Mysql search
October 22, 2008 08:20AM
<clipp>
> Am hoping someone out there can recommend a better script or maybe share some of your own code?
>
> Any help would be appreciated.

Do it right... read up on MySQL's fulltext matching.

Cheers,
Rob.
</clipp>

Did some searching based on your tip, got what i was looking for, just didnt know where to start.. and now feeling like the man who was taught how to fish :D

Thanks!
R





--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
tedd
Re: [PHP] Mysql search
October 23, 2008 02:50PM
At 11:16 PM -0700 10/21/08, Ryan S wrote:
>
><clipp>
>> Am hoping someone out there can recommend a better script or maybe
>>share some of your own code?
>>
>> Any help would be appreciated.
>
>Do it right... read up on MySQL's fulltext matching.
>
>Cheers,
>Rob.
></clipp>
>
>Did some searching based on your tip, got what i was looking for,
>just didnt know where to start.. and now feeling like the man who
>was taught how to fish :D
>
>Thanks!
>R

I often feel like a fish given a matchbook.

Cheers,

tedd

--
-------
http://sperling.com http://ancientstones.com http://earthstones.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Sorry, only registered users may post in this forum.

Click here to login