Function: RenderWebChanges

Replacement for TWiki's default WebChanges

Parameters

  • SKIP: topic offset
  • LIMIT: number of hits per page

Implementation

%STARTINCLUDE%
*~~
%~~ DBQUERY{
~~~    order="modified" 
~~~    limit="%IFDEFINED{"%LIMIT%" then="%LIMIT%" else="10"}%" 
~~~    reverse="on" 
~~~    skip="%SKIP%"
~~~    header="<noautolink>$n
~~~      | *&nbsp;* | *Topic* | *Type* | *Changed* | *Author* |"
~~~    format="
~~~      | $index 
~~~      | [[$web.$topic][$topic]] 
~~~      | $percntFORMATLIST{\"$formfield(TopicType)\" sort=\"on\" format=\"[[$web.$1][$1]]\"}$percnt
~~~      |  <span style=\"white-space:nowrap\">$formatTime(info.date)</span>  |  [[%MAINWEB%.$expand(info.author)][$expand(info.author)]]  |$n
~~~      | &nbsp; | <div style=\"margin:2px 10px 5px 0px;\">$flatten($expand(Teaser or Headline or TopicDescription or Text or 'no description')) </div>||||"
~~~    footer="$percntCALC{\"$dollarSET(nrTopics,$count)\"}$percnt$n</noautolink>"
~~~ }%
%~~ DBCALL{"RenderPageNavigation" 
~~~   SKIP="%SKIP%" 
~~~   MAX="%CALC{"$GET(nrTopics)"}%"
~~~   LIMIT="%IFDEFINED{"%LIMIT%" then="%LIMIT%" else="10"}%"
~~~ }%
*~~
%STOPINCLUDE%

Test

  Topic Type Changed Author   1 WebSearch   2009-08-21 - 15:53 DavidHammond
 
no description
2 WebIndex   2009-08-21 - 15:53 DavidHammond
 
no description
3 TopicType AdminTool, TopicType, TWikiFormAttribute 2009-08-21 - 15:53 DavidHammond
 
TopicType of all possible TopicTypes in the WEB web
4 TWikiTopic TopicType 2009-08-21 - 15:53 DavidHammond
 
TopicType of a normal TWiki topic
5 RenderWebTools TopicFunction 2009-08-21 - 15:53 DavidHammond
 
Render a tools sidebar section displayed when using PatternbSkin

Calls to 'RenderWebChanges'

TopicForm
TopicType TopicFunction
TopicDescription Replacement for TWiki's default WebChanges
Topic revision: r4 - 2009-06-04 - 14:26:39 - TWikiAdminUser
 
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors. Ideas, requests, problems regarding TWiki? Send feedback.