George Singer wrote:
Volkmar

Thanks for the reply. The problem is simple. I have a Javascript file
which works if included in my XSL in full.

However, when I replace it with an external file, containing EXACTLY
the same details, Cocoon cannot find it (despite the inclusion of the
reader below).

But you can serve external css files and images using a reader?


My question is, how do I make Cocoon use the file add.js ??

Cocoon cannot "use" a javascript file, it can only "read" it by a reader and send it to the browser.


Handling external *.js files by a reader is the same way as handling any other text file like text/css or text/plain or images like image/png.

If not, are you using a reader for supplying "add.js" like

<map:match pattern="**.js">
>    <map:read mime-type="text/javascript src="{1}.js"/>
> </map:match>

**** yes I am

And if you point your browser to "add.js"? Does Cocoon say it cannot find the ressource "add.js"? Did you try with Telnet to get the HTTP header for "add.js"?



I've searched around, some people suggest adding a space using:

<script language="JavaScript" type="text/javascript"
src="add.js">&#160;</script>


Why?

*** I do not know ? I just tried it as a last resort

<script language="JavaScript" type="text/javascript" src="add.js"></script>>
is ok. Leave it empty.




// this function uses the DOM to bring focus to the Shirt_Number textbox:


Why don't you use tabindex attribute?

**** what does it do ?

It makes element with tabindex="1" be the first in taborder. <http://www.w3.org/TR/html4/interact/forms.html#adef-tabindex>



--
Volkmar W. Pogatzki


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to