Forum OpenACS Q&A: Create alphabetical list of pages in Xowiki

Is there an established way to create an alphabetical <ul> of pages without having to set up a category tree or use the section field?

Regards
Richard

Collapse
Posted by Gustaf Neumann on
The easiest way is probably (based on the version of xowiki installed on openacs.org, was reformatted for this posting):
  • instantiate the "weblog-portlet": YOURHOST/xowiki/weblog-portlet
  • edit it: YOURHOST/xowiki/weblog-portlet?m=edit
  • replace the line where the instance of ::xowiki::Weblog is created
      set w [::xowiki::Weblog new -destroy_on_cleanup  -package_id $package_id \
        -page_size $page_size -page_number $page_number \
        -summary $summary -date $date  -category_id $category_id -tag $tag -ptag $ptag \
        -entries_of $entries_of  -exclude_item_ids $exclude_item_ids \
        -entry_renderer $entry_renderer  ]
    
    with
      set w [::xowiki::Weblog new -destroy_on_cleanup  -package_id $package_id \
        -summary 1 -date $date -category_id $category_id -tag $tag -ptag $ptag \
        -entries_of $entries_of  -exclude_item_ids $exclude_item_ids \
        -entry_renderer $entry_renderer -sort_composite none,title,asc ]
    
  • ... and save the page under a new name (e.g. page-list)
  • optionally, adapt the WeblogRenderer and EntryRenderer in the new page (page-list) to produce different output