Adding Site-wide Search in Sandvox Pro

The Sandvox Yahoo! group recently discussed adding a form to one's Sandvox website to enable visitors to search the site.

For a website to have its own truly built-in search function, it would have to have its own index of the contents of the website. That's beyond the scope of this article, though it could be set up by somebody who is handy with working with the "back end" of a website by installing a search engine like the open-source DataparkSearch like we do for our documentation website, or one of the many commercial search engines around there.

searchformsFor most Sandvox Pro users, on the other hand, it's actually easy to add a form for searching the website by using some other company's index of your website. Many of these have free options, or paid options if you don't want to show their advertisements.

There are several that we've found: Google Custom Search (or Google Site Search, which is geared toward larger businesses), PicoSearch, FreeFind, and FusionBot, to name a few. These will provide a form that you can paste into your website (as a Raw HTML pagelet in Sandvox); searchers will get their list of results from your website.

Be sure when you are creating the form that you specify a compact width, so that it will fit in the 200 pixels width of most pagelets on Sandvox sites.