README

Google Search Appliance XHTML Stylesheet

The Google Search Appliance XHTML Stylesheet defines a user interface for your Google Search Appliance that conforms to modern web standards including XHTML 1.0 Strict, XHTML Mobile Profile (XHTML-MP) and CSS 2.1. It generates well-formed, valid markup and is accessible in a variety of browsers and presentation modes. (Learn more about web standards.)

Table of Contents

Features

In handheld-exclusive mode, pages are further condensed and optimized for viewing on handheld devices. The WAP 2.0 compliant interface preserves Google Search Appliance features relevant to enterprise search while obeying many of the paradigms set forth by Google Mobile Search.

System Requirements

The Google Search Appliance XHTML Stylesheet has been road-tested and tire-kicked in the following user agents:

What's Included

How To Install

The Google Search Appliance provides support for multiple front end user interfaces to the same search engine. We leverage that feature to add XHTML and XHTML-MP support:

  1. Add a new Front End using your Google Search Appliance's Admin Console. See the documentation on the Google Enterprise support site for details on how to do this. Alternatively use the context sensitive help link in the Serve -> Front Ends section of your Admin Console.
  2. Modify the new Front End by importing the supplied stylesheet transformation, gsa-xhtml.en.xslt. See the documentation for details on how to do this. Alternatively select Edit for the new Front End and, on the Format tab, use the context sensitive help link for the XSLT Stylesheet Editor.
  3. Adjust XSLT variables to taste. Also configure linked style or configure handheld exclusive modes.
  4. Use the Admin Console's Test Center to sanity check that the stylesheet and Front End have been set up correctly. If you view frame source for the search page proper, you should see XHTML in the DOCTYPE line (instead of HTML).
  5. Publish the search link to your new Front End for all of your users:
    1. Open a browser and navigate to your Google Search Appliance.
    2. Copy the (rewritten) link from your browser address bar and paste into a text editor.
    3. Replace the values of the "client" and "proxystylesheet" parameters with the name of your new Front End.
    We recommend having a default page on a separate web server redirect to this link so that your users only need to remember (or bookmark) the simpler address (e.g., http://www.acme.com/search).

Linked vs. Embedded Style

By default, the Search Appliance embeds CSS appropriate for each request. To further improve performance, you may optionally link to the CSS instead. This allows style to be cached and save even more bandwidth. To configure:

  1. Copy the style directory (included) to your web server of choice.
  2. Set the variable style_include_prefix to a URL pointing to your new directory. Include the trailing slash.
  3. Change the variable style_include from 0 to 1 to enable linking.

Handheld-Exclusive Mode

In this mode, the XHTML and CSS sizes are reduced even further, to the point of supporting only handheld media. Enable by editing the XSLT as follows:

  1. Set the variable media to handheld.
  2. Comment out the xsl:output element referencing the XHTML 1.0 Strict Document Type Definition.
  3. Uncomment the xsl:output element referencing the XHTML Mobile 1.0 Document Type Definition.

(Steps two and three are required until XSLT 2.0 support is provided.)

A Note About OneBox and XHTML

Typical Google OneBox for Enterprise modules come packaged with their own XSLT to define the display of the OneBox section of the search results page. In most cases the resultant markup may not be well-formed and valid XHTML, nor styled for multiple presentation modes. To help remedy this try the following for each of your OneBox modules:

  1. Create a duplicate OneBox module with a different name but otherwise similar settings. This will be your XHTML/standards-friendly version of the original OneBox module.
  2. Replace the XSLT in the new module with that in the given onebox-xhtml.en.xslt stylesheet transformation.
  3. Assign this new OneBox module to your mobile Front End.
  4. Customize the XSLT to recapture the look and feel intended by the OneBox author while remaining consistent with screen, print and handheld display design principals.

Caveats and Known Issues

Handheld Media-specific Notes

Credits and Thanks

The Google Search Appliance XHTML Stylesheet was developed for Google Enterprise by Joe D'Andrea using the following tools:

Thanks are due to the following people for their generosity, advisement, and support:

Last, but not least, thanks to: