Hi All,
Thanks for all the responses. I got this solved by making my behavior extend
AbstractHeaderContributor. In its getHeaderContributors() I return the list
of headers only if response is not ajax. In case of ajax I simply return
null.
Regards,
Apple Grew
my blog @ http://blog.applegrew.com/
Another more complicated way seems to be using SharedResources and
DynamicWebResources, an example of this, you can find it on
"UploadStatusResource" class of
wicket.extensions.ajax.markup.html.form.upload package
--
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Strip
Good Afternoon,
I've working on this theme, and I found a solution to avoid the strip of our
resources.
On the Ajax Behavior, we put this lines:
ResourceStreamRequestTarget targetRes = new ResourceStreamRequestTarget( new
PackageResourceStream(MyScopeClass.class,"resources/myJS.js"));
targetRes
if (!AjaxRequestTarget.get())
renderMyJavascript();
On Thu, 22 Apr 2010 09:10 +0530, "Apple Grew"
wrote:
> I have a component which contributes Js headers. This component is also
> rendered by AjaxRequestTarget. The problem is that when rendering ajax
> response the Js codes too are getting r
x, yeah /shrug with the caveat for hosting solutions.
> >> >
> >> > tim
> >> >
> >> > -Original Message-
> >> > From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com]
> >> > Sent: Thursday, April 22, 2010 8:08 PM
> >> >
sting solutions.
>> >
>> > tim
>> >
>> > -Original Message-
>> > From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com]
>> > Sent: Thursday, April 22, 2010 8:08 PM
>> > To: users@wicket.apache.org
>> > Subject: Re:
ing solutions.
> >
> > tim
> >
> > -Original Message-
> > From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com]
> > Sent: Thursday, April 22, 2010 8:08 PM
> > To: users@wicket.apache.org
> > Subject: Re: Strip header contributors from Ajax respons
org.apache.wicket.markup.html.IHeaderContributor
-igor
On Thu, Apr 22, 2010 at 8:35 PM, Apple Grew wrote:
> @Igor
>
> I have a very tight budget so the resources are pretty limited, so I need to
> save the bandwidth wherever possible. BTW I didn't find any class -
> iheaderresponsecontributor.
>
Igor Vaynberg [mailto:igor.vaynb...@gmail.com]
> Sent: Thursday, April 22, 2010 8:08 PM
> To: users@wicket.apache.org
> Subject: Re: Strip header contributors from Ajax response.
>
> amd this bloating has caused a noticeable slowdown in your site's
> response times? how much
@Igor
I have a very tight budget so the resources are pretty limited, so I need to
save the bandwidth wherever possible. BTW I didn't find any class -
iheaderresponsecontributor.
Regards,
Apple Grew
my blog @ http://blog.applegrew.com/
On Fri, Apr 23, 2010 at 8:37 AM, Igor Vaynberg wrote:
> am
.
Inlined ajax, yeah /shrug with the caveat for hosting solutions.
tim
-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com]
Sent: Thursday, April 22, 2010 8:08 PM
To: users@wicket.apache.org
Subject: Re: Strip header contributors from Ajax response.
amd this bloating has
amd this bloating has caused a noticeable slowdown in your site's
response times? how much latency is it adding to the response?
that said, you can always output it using iheaderresponsecontributor
and add an check if you are inside ajax or not using request.isajax()
-igor
On Thu, Apr 22, 2010 a
Hi Igor,
It is not that duplicates items are getting rendered. What I want is that
the Js should be rendered ONLY when rendering in non-Ajax mode. In Ajax mode
the Js code should be stripped out. As these Js codes are not executed when
in Ajax response so it doesn't make sense to render them there
Hi Igor,
It is not that duplicates items are getting rendered. What I want is that
the Js should be rendered ONLY when rendering in non-Ajax mode. In Ajax mode
the Js code should be stripped out. As these Js codes are not executed when
in Ajax response so it doesn't make sense to render them there
wicket will filter duplicate contributions for you and even though
they are rendered they are not executed. if you are writing out
javascript directly you can set a string id which uniquely identifies
the contribution and wicket will also filter by that.
-igor
On Wed, Apr 21, 2010 at 8:40 PM, App
15 matches
Mail list logo