I have many HTML::Mason components that don't return content and are
just used as functions (return a value).
I would like to turn these into a set of subs in a module, preferably
an OO module. I'm wondering what the best way to do this is.
$m->comp('/path/to/component.mas', attr1 => "some value", attr4 =>
"4", attr2 => \%hash, attr0 => [EMAIL PROTECTED]);
/path/to/component.mas:
<%args>
$attr0 # things in args represent required parameters, ones with
values are defaults that are overridden by the passed value (if present)
$attr4 => 5
$attr1 => "defaultValue"
</%args>
<%init>
...stuff happens....
</%init>
Maybe I should ask Dave Rolsky?
Thanks!
Ryan
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>