Tags:
create new tag
, view all tags

Question

I'm trying to execute a formatted search that finds only the first-generation children of a topic. This can easily be done with METASEARCH, but the results are messy. Can this be done? Or is there a work-around? Any help is appreciated.

Environment

TWiki version: TWikiRelease04x00x04
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS:  
Web server:  
Perl version:  
Client OS:  
Web Browser:  
Categories: Documentation

-- TWikiGuest - 10 Oct 2006

Answer

ALERT! If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.

You can do a formatted SEARCH for a named parent topic. Untested example that lists all child topics of the current topic:

Children: %SEARCH{ "META:TOPICPARENT.*\"%TOPIC%\}" type="regex" nonoise="on" format="[[$topic]]" separator=", " }%

See details in VarSEARCH and FormattedSearch.

-- PeterThoeny - 28 Nov 2006

I don't see that documented in the linked topics.

-- ArthurClemens - 28 Nov 2006

A new case for the SearchPatternCookbook?

-- PeterThoeny - 29 Nov 2006

Just want to say that I've been looking for this solution, and it works. In my search string I simply substituted an actual TopicName for the %TOPIC% variable and put in some additional formatted search result syntax:

%SEARCH{ "META:TOPICPARENT.*\"BetaFeedback"\}" type="regex" nosearch="on" nototal="on" order="modified" reverse="on"  format="| [[$topic]] | $wikiusername | $date |" limit="20" }%
gave me a formatted table with just the child topics of BetaFeedback displayed.

Thanks!

-- DianeSexton - 16 May 2007

 
Change status to:
Topic revision: r5 - 2007-05-16 - DianeSexton
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.