[pmwiki-users] Search results

Hans design at softflow.co.uk
Wed Apr 26 17:17:54 CDT 2006


Wednesday, April 26, 2006, 10:26:22 PM, Seana wrote:
> Is there any way to get PM Wiki search results to be presented in a more
> user-friendly and relevant fashion? 

> I mean, instead of just displaying a list of pages that contain the search
> term, is there any provision for *relevance* of the search? Is there any way
> to get search results to display showing a tidbit of the matching text that
> appears in the body of the page? Finally, is there any way to get the PAGE
> NAMES that do display in search results to appear with spaces between the
> words, as opposed to allmashedupliketheyarenow? 

Your default pmwiki search uses the (:searchresults:) directive from
page Site.Search, and it uses the default pagelist format from page
Site.PageListTemplates.

You can change the format of search results by including a fmt=
parameter to the (:searchresults:) directive. You can also edit the
pagelist formats on Site.PageListTemplates. You can pretty well use
(:searchresults:) like (:pagelist:), so look up PmWiki.PageLists for
informatio about parameters and usage.

For instance to get the results with words spaced change the #default
format on Site.PageListFormat: change [[{=$Group}/{=$Name}]]
to [[{=$Group}/{=$Namespaced}]]

Have a look at more pagelist templates here:
http://www.pmwiki.org/wiki/Cookbook/PagelistTemplateSamples


Best,
 Hans                           





More information about the pmwiki-users mailing list