Mailing List Archive

Fwd: Using CSS / JS in execute
Just for the lists reference.

---------- Forwarded message ----------
From: Andrew OBrien <i.am.andrewo@gmail.com>
Date: 28 February 2015 at 16:49
Subject: Re: Using CSS / JS in execute
To: Donavon Lerman <donl@mycopanet.com>


Hi Donavon,

I'm not sure exactly what you mean but if I understand you correctly, then
if the CSS or JS is output to the browser in the wrapping file then the
content generated from the inner file will end up in the same browser page.
So, yes, you can reference things in the called epl's content.

It all depends on the final output sent to the browser.

For example see the below as an illustration.

index.html (or .epl or whatever your config says is an Embperl-handled
extension)

<html>
<head>
<title>CSS include test</title>
<link rel="stylesheet" type="text/css" href="mystyle.css">
<script src="my_js_functions.js"></script>
</head>
<body>
[- Execute('content.epl') -]
</body>
</html>

content.epl output can reference all styles in mystyle.css and all JS
defined in my_js_functions.js

Cheers,

Andrew

On 28 February 2015 at 09:20, Donavon Lerman <donl@mycopanet.com> wrote:

>
> Is there a way to use the CSS or JS of the calling .epl in the .epl that
> is called via execute?
>
> Thank You,
> ~Donavon
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
> For additional commands, e-mail: embperl-help@perl.apache.org
>
>