You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Mindaugas Genutis <mi...@elinara.ktu.lt> on 2004/03/01 09:22:59 UTC

Re: Integrating Javascript htmlArea

> Add the .js files as assets to your component. Then you can use the include-script and also access it using the getAsset("assetName").buildURL method to determine the editorURL.

Yes, but adding assets to the *.script components isn't allowed in 
Tapestry, is it? And the following string is written in Javascript, I 
won't be able to call it with getAsset(etc) ?

> > > cfg.editorURL = '/path/to/htmlarea/' ;

-- 
Kaunas Regional Distance Education Center
Programmer
Phone: +370 674 05232
WWW: http://distance.ktu.lt


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Integrating Javascript htmlArea

Posted by Fernando Donati <fe...@donati.com.br>.
Let me rephrase that. 

Use the include-script (I put everything in the same directory and just call <include-script resource-path="htmlarea.js"/>) and also add it as an asset to your component and pass the editorURL location to the script using 

symbols.put("editorURL", editorURL)

then in the script file you can just type in the line

cfg.editorURL = '${editorURL}' ;

Take a look at DatePicker.java and DatePicker.script, it will certainly help.

cheers

On Mon, 1 Mar 2004 10:22:59 +0200 (EET), Mindaugas Genutis <mi...@elinara.ktu.lt> escreveu:

> De: Mindaugas Genutis <mi...@elinara.ktu.lt>
> Data: Mon, 1 Mar 2004 10:22:59 +0200 (EET)
> Para: Tapestry users <ta...@jakarta.apache.org>
> Assunto: Re: Integrating Javascript htmlArea
> 
> > Add the .js files as assets to your component. Then you can use the include-script and also access it using the getAsset("assetName").buildURL method to determine the editorURL.
> 
> Yes, but adding assets to the *.script components isn't allowed in 
> Tapestry, is it? And the following string is written in Javascript, I 
> won't be able to call it with getAsset(etc) ?
> 
> > > > cfg.editorURL = '/path/to/htmlarea/' ;
> 
> -- 
> Kaunas Regional Distance Education Center
> Programmer
> Phone: +370 674 05232
> WWW: http://distance.ktu.lt
> 
> 
> ---------------------------------------------------------------------
> 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