PHP中的搜索功能 [英] Search function in php
本文介绍了PHP中的搜索功能的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
任何人都可以给我一个简单的运行程序代码,该程序提供多字搜索功能吗?
例如:
用户在一个文本字段中输入3个字: ,动物"和地球".
我想输出所有包含这3个词的搜索,但不完全匹配规则.
例如,它将输出完整的句子,例如:地球上的人,动物也一样"
我说的是根据数据库信息的搜索.
非常感谢所有帮助
Can anyone give me a simple code of running program that provide a multiwords search function?
for example:
user input 3 words in one text field: "people" , "animal", and "earth".
I want to output all the search contains this 3 words but not according to the exact match rules.
for example it will output the full sentence like: "people living in earth, so do animal"
I am talking here according to search in database information.
All the help much appreciated
推荐答案
检查这些链接
http://msdn.microsoft.com/en-us/library/ms173746.aspx [ ^ ]
http://stackoverflow.com/questions/2305362/php-search-string-with-wildcards [ ^ ]
http://stackoverflow.com/questions/2488483/wildcard-php-text-search [ ^ ]
Check these links
http://msdn.microsoft.com/en-us/library/ms173746.aspx[^]
http://stackoverflow.com/questions/2305362/php-search-string-with-wildcards[^]
http://stackoverflow.com/questions/2488483/wildcard-php-text-search[^]
这篇关于PHP中的搜索功能的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文