I finally have the introspection template I was looking for when I started
this thread.

The author of Template::Plugin::Stash kindly made a change that makes it
possible without the need for any other modules.

If you would like to use it, install Template::Plugin::Stash from CPAN and
grab the following files:
  - variables.css (http://www.markthomas.org/variables.css
<http://www.markthomas.org/variables.css> )
  - variables.tt (listing at http://www.markthomas.org/variables.tt.html
<http://www.markthomas.org/variables.tt.html> )
  - variables2.tt (listing at http://www.markthomas.org/variables2.tt.html
<http://www.markthomas.org/variables2.tt.html> )

Demo output, from a perl script that gives the template a data structure
full of gibberish:
http://markthomas.org:8080/perl/test.pl/variables.tt
<http://markthomas.org:8080/perl/test.pl/variables.tt> 

As you can see, it makes it easy for a non-programmer to construct a proper
variable name, as they just follow the blue path to the value they are
looking for. I color-coded the arrays differently, so that a non-programmer
can know when they can say [% FOREACH item IN variable.name %]

My next steps are:
  - Use this idea to auto-populate documentation templates.
  - Look into the possibility of handling coderefs, and any other custom
constructs available to the template user.


-- 
Mark Thomas                    [EMAIL PROTECTED]
Internet Systems Architect     User Technology Associates, Inc.

$_=q;KvtuyboopuifeyQQfeemyibdlfee;; y.e.s. ;y+B-x+A-w+s; ;y;y; ;;print;;
 


_______________________________________________
templates mailing list
[EMAIL PROTECTED]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to