17 Jul 2005 MichaelCrawford   » (Master)

Ask Advogato: How To Implement Site Search?

Can you suggest an open source package that will allow me to provide a search form on my pages whose search is restricted to my site? I need to be able to include a snippet of javascript in the search results to place Google AdSense ads in the results.

The is something called AdSense for Search, but it sends a lot of unpaid traffic away from my site. Paid ads are presented in the search results, but the pay per click is very poor, not enough I think to justify sending people away from my domain.

A short-term solution that won't make me ad revenue but should improve my site traffic is a hand-coded non-affiliate search box that uses Google to search my site by including a hidden form field that adds "site:goingware.com" as a keyword. Here is how such a search would result if one were to put such a search box here:

Now, I wouldn't get paid for ad clicks in those searches, but I think that's fair considering that I'm asking google to handle the searches. My reason for wanting site search is mainly to improve navigation at my site. I have already found that improved navigation on my pages drives up traffic throughout my site, as people spend time exploring it rather than going elsewhere. I figure offerring a search within my domain would improve that effect.

The adsense terms of service have been revised to allow ads to be placed in search results that adsense publishers generate. These are not the same as adsense for search, but are just like ads placed in static pages. The pay per click is much better, so that although I would lose a visitor when they clicked an ad, I would be paid well enough that it's worthwhile.

My web hosting service runs apache and mysql. I'm not sure what other web technologies they support. They're very busy people so I don't want to ask them to install any software they don't absolutely have to.

htDig is very popular but I've never been happy with its effectiveness. Maybe it is better now than it used to be. There must be many site search packages available, and I know I could find them all at Freshmeat, but I would prefer specific recommendations.

If you don't want to reply in your diary, send email to goingware (a|t) g m a i l dot com. My crawford@goingware.com email is deluged with spam because I have never protected it.

Thanks a million!

Latest blog entries     Older blog entries

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!