O'Reilly logo

Core PHP Programming, Third Edition by Leon Atkinson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

19.3. MnoGoSearch

MnoGoSearch is a Web site search engine, formerly known as UdmSearch. It works by following links on a Web site to build a database of keywords. Although you may use it by itself, it can be more convenient to access the engine directly from PHP.

You can find more information about MnoGoSearch at the home site: <http://www.mnogosearch.ru/>. Listing 19.12 demonstrates use of the MnoGoSearch functions.

Listing 19.12. Using MnoGoSearch
 <?php if(!isset($_REQUEST['query'])) { $_REQUEST['query'] = ''; } if(!isset($_REQUEST['page'])) { $_REQUEST['page'] = 0; } //connect to search engine $agent = udm_alloc_agent('mysql://user@localhost/mnogo/'); //only return English documents udm_add_search_limit($agent, UDM_LIMIT_LANG, 'en'); //ignore ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required