Re: [EP-tech] load a javascript and css only in abstract pages

Yuri via Eprints-tech <[email protected]>
Newsgroups gmane.comp.web.eprints.devel
Message-ID <EMEW3|eac83842e252c1013bbb8123a1164108v9S7YH14eprints-tech-bounces|ecs.soton.ac.uk|[email protected]>
Sorry, I've found eprint_render can manage head too:


=== at the end of eprint_render ===

     foreach my $key (keys %fragments)
     {
         $fragments{$key} = [$fragments{$key}, "XHTML"];
     }

     my $page = $eprint->render_citation("recollect_summary_page",
%fragments,
                                         flags => $flags);

     my $title = $eprint->render_citation("brief");
     my $links = $repository->xml()->create_document_fragment();
     if (!$preview)
     {
$links->appendChild($repository->plugin("Export::Simple")
                             ->dataobj_to_html_header($eprint));
         $links->appendChild(
$repository->plugin("Export::DC")->dataobj_to_html_header($eprint));
     } ## end if (!$preview)

     return ($page, $title, $links);
===

Il 29/10/19 08:24, Yuri ha scritto:
> Hi!
>
>  I need to insert a css and some javascript in the abstract pages (and
> only there). For javascript I can use the eprint_render method to
> insert them in the page. But what about css? The can be linked (they
> are not small and came from a cdn) only in the head section. The page
> is composed after the eprint_render method, so I don't know if I can
> mess up with <head> in eprint_render.
>
> Any idea?
>

*** Options: http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech
*** Archive: http://www.eprints.org/tech.php/
*** EPrints community wiki: http://wiki.eprints.org/
*** EPrints developers Forum: http://forum.eprints.org/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.