1.5 Javascript HeaderContribution

2011-01-27 Thread Todd Wolff
Hi,

 

Struggling with new HeaderContribution semantics ...  Trying to
dynamically add a javascript reference to header section. 

 

My old code (that worked):

 

add(JavascriptPackageResource.getHeaderContribution(js/fb-auth-redirect
.js));

 

Tried refactoring (unsuccessfully) as:

 

response.renderJavaScriptReference(new
PackageResourceReference(js/fb-auth-redirect.js)); 

 

What is the correct way to duplicate the old logic?  Thanks.



Re: 1.5 Javascript HeaderContribution

2011-01-27 Thread Igor Vaynberg
response.renderJavaScriptReference(SomeClassInThePackage.class,
js/fb-auth-redirect.js);

-igor

On Thu, Jan 27, 2011 at 3:44 PM, Todd Wolff todd.wo...@utsa.edu wrote:
 Hi,



 Struggling with new HeaderContribution semantics ...  Trying to
 dynamically add a javascript reference to header section.



 My old code (that worked):



 add(JavascriptPackageResource.getHeaderContribution(js/fb-auth-redirect
 .js));



 Tried refactoring (unsuccessfully) as:



 response.renderJavaScriptReference(new
 PackageResourceReference(js/fb-auth-redirect.js));



 What is the correct way to duplicate the old logic?  Thanks.



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org