cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeffrey_M_Gross...@Countrywide.Com
Subject Re: kinda OT: problems generating javascript from xsl
Date Wed, 13 Sep 2000 00:17:47 GMT

One thing that we do is not to imbed the javascript in the page, but to
include the javascript file

In other words, our xsl looks like:

<SCRIPT LANGUAGE="JavaScript" SRC="script.js"/>

This way the client browser is able to cache the java script file, and you
never have to CDATA your java script!

Jeffery Grossman
Countrywide Home Loans


Hi everyone,

Maybe someone here can give this a shot.  I have some javascript I want to
run on the client side, so in my final xsl stylesheet I have something like

<script Language="JavaScript">
remove the primer option if it is still there.



if (toObj.options[0].value=="primer") toObj.options[0] = null


//blah blah

                    // ]]></xsl:comment>

I get some wacky error about conditional commands not being set or

I noticed that when i do a "view source" in the browser, all my javascript
gets flattened into one line.  I would assume that the browser doesn't know
that that there are supposed to be seperate lines of code in there, and
maybe the browser's javascript interpreter is trying to parse html beyond
what's in the script tags because of that.  How can I get xsl to preserve
the carraige returns in my javascript?


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message