Mark Hedges wrote:
>IMO, rewrite the system for Catalyst. It will probably cause
>you too much headache to convert. I want to learn Catalyst.
>That stuff is cool. BTW check out DBIx::Class as the storage.
>
>Mark
>
>On Wed, 14 Jun 2006, J Cook wrote:
>
>
>
Yeah, Catalyst looks very interesting - the only thing is its
documentation is usually either stale or lacking - IMO.
The deal here is that I've written some functions into these Mason
components that I don't want to have to write over. Its not just things
to write html pages but a bunch of stuff that post to other site via
LWP, interfacing with Payflow Pro and Authorize.net that I'm not keen on
rewriting - well with the least rewriting possible. For instance if had
a component call like:
<& 'some/comp.mas', foo => $foo, bar => "baz", %ARGS %>
What would I change it to, but more importantly in 'some/comp.mas':
<%args>
$foo
$bar
</%args>
...some code...
if ($ARGS{'who'} eq "you") {
...
}
...
I often read that most Mason gurus just use Mason for the view and do
all the functions etc in Perl modules, maybe one of you could show me
and example of how you would handle it.
Justin
>>From: J Cook <[EMAIL PROTECTED]>
>>To: [email protected]
>>Date: Wed, 14 Jun 2006 10:31:51 -0400
>>Subject: [Mason] Converting .mas component to perl module - Any Suggestions?
>>
>>I made the mistake of using Mason components where I should have made
>>Perl modules. On one hand its nice because I don't have to restart
>>apache every time I modify a component file, but I guess that I am
>>taking a performance hit for doing things this way. I used Mason like
>>someone would use PHP you could say(and my Perl is like Mason-flavored
>>slang).
>>
>>But now I'm looking at making some applications in Catalyst, and I want
>>to make these Mason components Perl modules so I can use them in these
>>new apps.
>>
>>So the question is - does anyone have any suggestions on the best way to
>>convert a .mas component to a Perl module? Take into consideration that
>>I'm passing arguments around using <%args> as well as %ARGS in many of
>>these components. Anyone?
>>
>>TIA
>>
>>Justin
>>
>>
>>
>>_______________________________________________
>>Mason-users mailing list
>>[email protected]
>>https://lists.sourceforge.net/lists/listinfo/mason-users
>>
>>
>>
>
>
>
_______________________________________________
Mason-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mason-users