You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Shark <bl...@gmail.com> on 2004/12/03 22:37:21 UTC
Re: javascript
Related question;
Does this apply to images in a component, I used a direct link <img
src='images/test.gif"> and this is not rendered. Do I have to use a
jwcid="@Image" for images in a component?
S.
On Tue, 30 Nov 2004 13:08:22 -0000, Dyson, Jimmi <dy...@quindell.com> wrote:
> The script file attribute needs to point to a script file that adheres to
> the Script_3_0.dtd (http://jakarta.apache.org/tapestry/dtd/Script_3_0.dtd),
> rather than a normal JavaScript file.
>
> If you just want to include the script in your HTML with no substitutions,
> etc. being made, I would recommend just using a normal "script" tag in your
> html template, rather than a Script component. Then there's no more
> processing for Tapestry to do to include your JS file.
>
> I'm sure you've looked at the example
> (http://jakarta.apache.org/tapestry/doc/ComponentReference/Script.html), but
> take another look at what is actually going on with the FormFocus.script -
> its not just an ordinary JavaScript file. Also check out the part of the
> developer's guide detailing the script usage
> (http://jakarta.apache.org/tapestry/doc/DevelopersGuide/script.html).
>
>
>
> -----Original Message-----
> From: Charles Brands [mailto:cbrands@linuxmail.org]
> Sent: 30 November 2004 10:29
> To: tapestry-user@jakarta.apache.org
> Subject: javascript
>
> Hi
> I am new to tapestry and I am trying to get my tapestry application to work=
> with javascript.
> I work in Eclipse. The directory structure looks like this
>
> myapp
> |
> |---src
> | |
> | -mypkg
> | |
> | -Home.java
> |
> |--WEB-INF
> | |
> | -Home.page
> |
> |-Home.html
> |-myscript.js
>
> Everything works except the javascript When I call the javascript I get a r=
> untime exception
> Unable to parse script context:/myapp/new/elmo.js.
>
> The following snippet is in my Home.html file
> <body jwcid=3D"@Body">
> <span jwcid=3D"@Script" script=3D"/myscript.js"/>
>
> However when I type in the browser
> http://localhost/myapp/myscript.js
> I can see that the script is there
>
> I am mystified any help is welcome
> thanks
> Charles Brands
> --
> ______________________________________________
> Check out the latest SMS services @ http://www.linuxmail.org
> This allows you to send and receive SMS through your mailbox.
>
> Powered by Outblaze
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org