create new tag
, view all tags

Feature Proposal: Include Parameters With Default


The ParameterizedIncludes is a powerful feature to build a library of components. Dynamic behavior can be done by supplying parameters to INCLUDEs. There is currently no easy way to take action on optional parameters. The new ParameterizedVariables feature supports defaults, so does VarURLPARAM. This proposals adds a defaults to parameters passed to INCLUDEs.

Description and Documentation

When you do this: %INCLUDE{ "Library" section="alertbox" title="Hello" message="This is a test." }%

You typically have a %title% and %message% in the alertbox section to show the title and message, respectively. This proposal adds optional defaults to these variables, such as %title{ default="Alert!" }% and %message{ default="Please specify a message parameter" }%



-- Contributors: PeterThoeny - 2011-04-05


This proposal is now accepted by the 7 days review period.

-- PeterThoeny - 2011-04-13

This is now implemented and documented in SVN trunk. See VarINCLUDE, IncludeTopicsAndWebPages.

-- PeterThoeny - 2011-04-14

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r3 - 2011-04-14 - PeterThoeny
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2018 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.