[Catalyst] XML RPC Server and RenderView

John Napiorkowski jjn1056 at yahoo.com
Sat Aug 25 16:27:22 GMT 2007


--- Nicolas Raspail
<nicolas.raspail at whisperingvault.net> wrote:

> Matthieu Codron a écrit :
> > Hi,
> > 
> > 
> >> Nicolas Raspail wrote:
> >>
> >>> Hello,
> >>> when playing with
> Catalyst::Plugin::Server::XMLRPC following the 
> >>> documentation, I get the same behaviour as Joe.
> >>
> >> Hmmm.... I thought it was just me.
> >>
> >>> I have search the archive and found thie mail
> from Joe Landman , and 
> >>> he has the same problem, but unfortunately,
> nobody answer him.
> >>
> >> True.  I am guessing that this is due to few
> people using XMLRPC in 
> >> Catalyst.  This is a shame as it really looks
> like a nice module to 
> >> use , and is exactly what I want to do ...  I
> have since hacked what I 
> >> need to do into some controllers/display logic
> outside of XMLRPC, 
> >> though I would rather get XMLRPC going.
> >>
> > 
> > I'm using this Catalyst::Plugin::Server::XMLRPC
> alongside RenderView 
> > without problems. To avoid forwarding to
> RenderView, I'm just putting a 
> > value in the response body at the end of the
> action, e.g. 
> > $c->response->body(1);
> > Looks like a hack, but it works. The contents of
> the response body are 
> > overwritten by the plugin.
> > 
> Hi Matthieu,
> 
> yes, I'm doing the same thing, but as you said, that
> looks like a hack, 
> and I would like to be sure it is the right thing to
> do
> 
> Thanks
> 
> Nicolas

Hi,

If Iam creating a site with mixed content (HTML pages
and XMLRPC for interactive stuff) I usually create a
base controller called 'ServicesController.pm' or
something and then I put an end action in that
controller.  That way it doesn't get to RenderView in
your root controller.

RenderView is a great way to get started but don't let
that stop you from creating end actions or forwarding
to views as needed.  That's way the Controller will
look in itself for an end action first.

Some of the Catalyst defaults become less useful the
more you create complexity or have needs beyond
rendering simple templates from database data.

--john


       
____________________________________________________________________________________
Pinpoint customers who are looking for what you sell. 
http://searchmarketing.yahoo.com/



More information about the Catalyst mailing list