Displaying meta tag values in results, Enhancing search results – Google Search Appliance Creating the Search Experience User Manual
Page 123
Google Search Appliance: Creating the Search Experience
Advanced Customization Topics
123
4.
Scroll to the end of the form parameters template,
5.
Between the template's closing tag and the preceding tag, add hidden input fields for all
parameters you want to submit from the search form. For example, to retrieve all meta tag values in
the results, add this line:
6.
Save the stylesheet. If you are using an external editor other than the Admin Console's XSLT
Stylesheet Editor, you must also import the stylesheet into the associated front end.
7.
Verify the changes by submitting a search from the modified search box and checking the URL
string for the specified parameters.
Displaying Meta Tag Values in Results
The custom front end for the “Inline Frame Example page” on page 114 is configured to show meta tags
in the results. Each result displays the three meta tags, rank, price, and fly-type, that are explicitly
retrieved by the custom search form:
To modify a front end to show meta tags in results:
1.
Open the stylesheet in the Admin Console's XSLT Stylesheet Editor or your preferred editor.
2.
Scroll to the section heading, .
3.
Inside this section, s et the variable show_meta_tags to a non-zero value:
4.
Save the stylesheet. If you are using an external editor other than the Admin Console's XSLT
Stylesheet Editor, you must also import the stylesheet into the associated front end.
5.
Make sure that the search parameter getfields is included in search requests, and that it is
assigned the correct values to retrieve the desired meta tags. For more information on the
getfields query parameter, see the Search Protocol Reference.
6.
Verify the changes by submitting a search that returns results that contain meta tags, and check
that the meta tag values are displayed.
Enhancing Search Results
Customization can serve your goals for the visual effect and content of results pages. This section
describes two ways to enhance results pages: including image links in results, and replacing the result
snippet with customized text.