A-Z listing portlet

NOTE! As of SiteVision 3, this portlet replaces earlier versions of the A-Z portlet (that wasn't using the SiteVision Public API).

The custom Velocity template in this portlet uses the JCR (Java Content Repository, JSR 283) programming model. The SiteVision API is available here

Elements available in the Velocity Context
NameType and Description
requestjavax.portlet.PortletRequest
 The portlet request
portletjavax.jcr.Node
 This portlet. See available properties in table below
jcrSessionjavax.jcr.Session
 The JCR Session
sitevisionUtilssenselogic.sitevision.api.Utils
 The main entry point to all utility classes
velocityEvaluatorsenselogic.sitevision.api.render.velocity.VelocityEvaluator
 A evaluator that can parse Velocity templates or Velocity expressions on the fly
searchResultsenselogic.sitevision.api.search.SearchResult
 The search result that holds all hits
Additional properties available for the portlet element ($portlet)
NameType and Description 
 Letter and querying 
autoSelectFirstLetterjavax.jcr.PropertyType.BOOLEAN 
 Whether or not to auto select first letter (likely A) if no specific letter query was invoked 
letterFontjavax.jcr.PropertyType.WEAKREFERENCE 
 The letter font Node (sv:font) 
selectedLetterFontjavax.jcr.PropertyType.WEAKREFERENCE 
 The selected letter font Node (sv:font) 
searchFieldjavax.jcr.PropertyType.STRING 
 What field to query ("nameField" or "titleField", see fields section below) 
ajaxLetterBaseURLjavax.jcr.PropertyType.STRING 
 Base URL to use for Ajax querying calls  
idMarkerjavax.jcr.PropertyType.STRING 
 The unique id marker 
letterMarkerjavax.jcr.PropertyType.STRING 
 The unique letter marker 
contentMarkerjavax.jcr.PropertyType.STRING 
 The unique content marker 
selectedLetterjavax.jcr.PropertyType.STRING 
 The letter that is queried 
   
 Type restrictions 
includeFilesjavax.jcr.PropertyType.BOOLEAN 
 Whether or not to include files in the search result 
includeImagesjavax.jcr.PropertyType.BOOLEAN 
 Whether or not to include images in the search result 
includePagesjavax.jcr.PropertyType.BOOLEAN 
 Whether or not to include pages in the search result 
includeArticlesjavax.jcr.PropertyType.BOOLEAN 
 Whether or not to include articles in the search result 
includeStructurePagesjavax.jcr.PropertyType.BOOLEAN 
 Whether or not to include structure pages in the search result 
   
 Search failed 
showSearchErrorjavax.jcr.PropertyType.BOOLEAN 
 Whether or not to show search errors or no hits messages 
errorMessagejavax.jcr.PropertyType.STRING 
 An i18n:ized message describing why search could not be executed 
searchErrorFontjavax.jcr.PropertyType.WEAKREFERENCE 
 The search error font Node (sv:font) 
   
 Index fields 
summaryFieldjavax.jcr.PropertyType.STRING 
 Name of the summary field 
titleFieldjavax.jcr.PropertyType.STRING 
 Name of the title field 
nameFieldjavax.jcr.PropertyType.STRING 
 Name of the name field 
namepathFieldjavax.jcr.PropertyType.STRING 
 Name of the name path field 
urlFieldjavax.jcr.PropertyType.STRING 
 Name of the absolute URL field 
uriFieldjavax.jcr.PropertyType.STRING 
 Name of the relative URL field 
lastPublishedFieldjavax.jcr.PropertyType.STRING 
 Name of the last published field 
sizeFieldjavax.jcr.PropertyType.STRING 
 Name of the size field 
siteFieldjavax.jcr.PropertyType.STRING 
 Name of the site field 
mimetypeFieldjavax.jcr.PropertyType.STRING 
 Name of the mime type field 
   
 Search hits 
showSearchHitNumberingjavax.jcr.PropertyType.BOOLEAN 
 Whether or not search hits should be displayed numbered 
showFileIconsjavax.jcr.PropertyType.BOOLEAN 
 Whether or not a file icons should be displayed for each search hit 
useSearchHitBackgroundColorjavax.jcr.PropertyType.BOOLEAN 
 Whether or not a searchHitBackgroundColor (see line below) are in use 
searchHitBackgroundColorjavax.jcr.PropertyType.WEAKREFERENCE 
 The background color for every odd search hit (sv:color) 
   
 Misc 
useCustomIndexjavax.jcr.PropertyType.BOOLEAN 
 Whether or not a custom index is used 
   
 Aggregated portlet preferences/settings: 
lettersjavax.jcr.PropertyType.WEAKREFERENCE 
 A temporary Node holding all sub-templates used by the main template. See available properties in table below 
templatesjavax.jcr.PropertyType.WEAKREFERENCE 
 A temporary Node with sub-nodes that holds properties about all letters. See available properties for letters sub-nodes in table below 
bundlejavax.jcr.PropertyType.WEAKREFERENCE 
 A temporary Node holding all i18n:ized texts used for output. See available properties in table below 
Properties available for sub-nodes of the letters Node
NameType and Description 
letterjavax.jcr.PropertyType.STRING 
 The letter 
isSelectedjavax.jcr.PropertyType.BOOLEAN 
 Whether or not this letter is selected 
letterURLjavax.jcr.PropertyType.STRING 
 The search URL for this letter 
Properties available for the templates Node
NameType and Description 
lettersTemplatejavax.jcr.PropertyType.STRING 
 The letters listing Velocity template 
lettersScriptTemplatejavax.jcr.PropertyType.STRING 
 The letter script Velocity template 
hitsTemplatejavax.jcr.PropertyType.STRING 
 The search hits Velocity template 
noHitsTemplatejavax.jcr.PropertyType.STRING 
 The no hits/search error Velocity template 
Properties available for the bundle Node
NameType and Description 
noPagesFoundStartingWithTextjavax.jcr.PropertyType.STRING 
 The i18n:ized search tip text (en: "Could not find any pages that starts with") 

Denna sida publicerades: 2012-05-14

Skriv ut PDF-avsnitt

Hjälpte informationen på den här sidan dig?

Missa inga nya rön, tips och tricks! Prenumerera på insite!

Find us!

SiteVision AB (Headquarter)
Vasagatan 10
702 10 Orebro
Sweden

Info: +46 19-17 30 30
Support: +46 19-17 30 39

Latest Tweets