Aristotle Pagaltzis wrote:
* Emmanuel Quevillon <[EMAIL PROTECTED]> [2008-04-30 15:05]:
Catalyst always try to wrap the action result 'display' into a
template.

No, it doesn’t. If that happens in your app, then you have set it
up to happen like that. But the code you pasted does not include
that portion, so no one will be able tell you what to do instead.

Regards,


Thanks Aristotle,


Maybe I can clarify the situation.

In controller Foo I have 2 methods:

sub bar : LocalRegex ('^(\d+)$') {

    my($self, $c) = @_;

    my $id = $c->req->captures->[0];
    $c->detach(qw/Root _softwareError/,
               ["An id is required to get related genes."])
      unless $id;

    $c->stash()->{url}      = $c->uri_for("/admin/rg/$id");
    $c->stash()->{template} = 'admin/relatedgenes.tt2';
    $c->detach('View::TT');

}

sub rg : Local : Args(1) {


    my($self, $c) = @_;

    my $id = $c->req->args->[0];
    $c->detach(qw/Root _softwareError/,
               ["An id is required to get related genes."])
      unless $id;

    my $gr = GeneRelations->new(
        %{$c->config()->{dbinfos}},
        org  => $c->session()->{org}->{id_org},
       );

my $t = $gr->display_graph(type => 'id_gene', value => $id);
    $c->res->write($t);
    $c->forward('Root', 'end');

}


Template 'admin/relatedgenes.tt2' contains an <object> tag as :

<object data="[% url %]" width="100%" height="100%"></object>

with [% url %] value coming from 'Foo::bar'
here: <object data="http://..../rg/<id>"></object>

I know that <object> tag can contain an url to be call on load, and that's what I want to do with My app to avoid storing svg files. If I put url for a svg image it works fine. But I don't want to store temp files.

I hope the situation will be clearer like this and someone will be able to give clues or solutions.

Thanks in advance

Emmanuel

--
-------------------------
Emmanuel Quevillon
Biological Software and Databases Group
Institut Pasteur
+33 1 44 38 95 98
tuco at_ pasteur dot fr
-------------------------


_______________________________________________
List: [email protected]
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[email protected]/
Dev site: http://dev.catalyst.perl.org/

Reply via email to