Re: Feedback panel inherits parent panel feebdack?

2011-09-26 Thread Dan Retzlaff
I've hit this too. You're not the first to be surprised by this behavior.
http://apache-wicket.1842946.n4.nabble.com/Page-and-compoenent-level-feedback-are-mixing-together-td1846435.html

I agree that there's something unintuitive about all FeedbackPanels
rendering all messages, but I haven't devised an alternate strategy that
works universally well. For example, any exclusive FeedbackPanel selection
criterion gets difficult when only one FeedbackPanel or another is rendered
in an AJAX response.

ContainerFeedbackMessageFilter might be a good fit for your inner
FeedbackPanel. I'd be interested to hear what you or others use for their
"catch all" FeedbackPanels.

Dan

On Mon, Sep 26, 2011 at 10:51 PM, Arjun Dhar  wrote:

> Hey, i guess i was sleeping when this one was taught.
>
> I have a Feetback panel on the parent panel.
> Then in a WebMarkupContainer, have added another feedback panel.
>
> When I add .info(...) or .error(...) to feedback panel in parent it appears
> in both.
>
> Must be some component hierarchy trickle down effect but Weird right?
> And if this is intentional why is it needed?
>
> -
> Software documentation is like sex: when it is good, it is very, very good;
> and when it is bad, it is still better than nothing!
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Feedback-panel-inherits-parent-panel-feebdack-tp3846252p3846252.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Feedback panel inherits parent panel feebdack?

2011-09-26 Thread Igor Vaynberg
all feedback panels get all feedback messages. use
ifeedbackmessagefilter provided impls or your own to filter messages
that panels consume...

-igor


On Mon, Sep 26, 2011 at 10:51 PM, Arjun Dhar  wrote:
> Hey, i guess i was sleeping when this one was taught.
>
> I have a Feetback panel on the parent panel.
> Then in a WebMarkupContainer, have added another feedback panel.
>
> When I add .info(...) or .error(...) to feedback panel in parent it appears
> in both.
>
> Must be some component hierarchy trickle down effect but Weird right?
> And if this is intentional why is it needed?
>
> -
> Software documentation is like sex: when it is good, it is very, very good; 
> and when it is bad, it is still better than nothing!
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Feedback-panel-inherits-parent-panel-feebdack-tp3846252p3846252.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Feedback panel inherits parent panel feebdack?

2011-09-26 Thread Arjun Dhar
Hey, i guess i was sleeping when this one was taught.

I have a Feetback panel on the parent panel.
Then in a WebMarkupContainer, have added another feedback panel.

When I add .info(...) or .error(...) to feedback panel in parent it appears
in both.

Must be some component hierarchy trickle down effect but Weird right?
And if this is intentional why is it needed? 

-
Software documentation is like sex: when it is good, it is very, very good; and 
when it is bad, it is still better than nothing!
--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Feedback-panel-inherits-parent-panel-feebdack-tp3846252p3846252.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: How to handle errors in RequestCycle.onEndRequest

2011-09-26 Thread Hans Lesmeister 2
Hi,

maybe you can override WebRequestCycleProcessor.respond:

but I did not try if that's too late as well


-
-- 
Regards, 
Hans 

http://cantaa.de 

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/How-to-handle-errors-in-RequestCycle-onEndRequest-tp3824649p3846249.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Servlet and Wicket

2011-09-26 Thread koha...@gmail.com
Here is what the architecture of my implementation looks like:

Dispatcher Servlet
(awaiting incoming httpservletRequest)
  |
Wicket Components

On the Application Service layer, I have 

   EJB Beans

And then on the Data Layer I have 
 JPA/Entity

My question is what should I be concerned about in accessing Wicket
Components from the Servlets since the URL would be connecting directly to
servlets.

I know how this works with JSP but I don't know how to access Wicket apps
from Servlets. Any examples you have would be helpful. We have to have the
Servlets in front due to current connection from IIS and Apache. Your help
or best practices on this would be appreciated.






--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3846081.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Servlet and Wicket

2011-09-26 Thread koha...@gmail.com
In my implementation I have in the presentation layer I have:
Interfacing with Http web Server (with IIS and apache http server)

Dispatcher Servlet
(awaiting incoming httpservletRequest)
  |
Wicket Components

On the Application Service layer, I have

   EJB Beans

And then on the Data Layer I have
 JPA/Entity

My question is what should I be concerned about in accessing Wicket
Components from the Servlets since the URL would be connecting
directly to servlets.

I know how this works with JSP but I don't know how to access Wicket
apps from Servlets. Any examples you have would be helpful. We have to
have the Servlet in from due to current connection from IIS and
Apache. Your help or best practices on this would be appreciated.








On Mon, Sep 26, 2011 at 6:34 PM, Igor Vaynberg-2 [via Apache Wicket]
 wrote:
> On Mon, Sep 26, 2011 at 3:06 PM, [hidden email] <[hidden email]> wrote:
>> I am asking this question because I have reviewed all the books published
>> on
>> Wicket including the recent Wicket Cookbook, I have not seen any examples
>> of
>> how you can replace JSP with Wicket. I want to use Wicket in my current
>> project but it would be cost prohibitive if I have to discard all the
>> Servlet implementation.
>
> wicket and servlets can live side-by-side. wicket doesnt take over the
> url space so servlets and jsps can still be accessed like they used to
> be.
>
>> Now, my question is, how easy would it be to replace
>> the JSP code with Wicket code. Or to ask it another way. Is it possible to
>> reuse my current Servlet code and integrate it with Wicket for the UI. It
>> would help to see examples of how to integrate Servlet code with Wicket.
>
> define "integrate"
>
> -igor
>
>
>>
>> I hope this helps clearify things a bit.
>>
>> --
>> View this message in context:
>> http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3845548.html
>> Sent from the Users forum mailing list archive at Nabble.com.
>>
>> -
>> To unsubscribe, e-mail: [hidden email]
>> For additional commands, e-mail: [hidden email]
>>
>>
> -
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
>
> 
> If you reply to this email, your message will be added to the discussion
> below:
> http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3845612.html
> To unsubscribe from Servlet and Wicket, click here.


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3846073.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Show ModalWindow when a RuntimeException occurrs

2011-09-26 Thread jchappelle
Hi, 

Currently I have subclassed the RequestCycle and overridden the
onRuntimeException method in it to return a custom error page for the user.
It works very well but the only problem is that it takes the user away from
the page they were on. I would like to be able to show a ModalWindow with a
custom error message in it when an uncaught runtime exception occurrs. 

Does anyone have any tips on how to do this? 

Thanks, 

Josh

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Show-ModalWindow-when-a-RuntimeException-occurrs-tp3845808p3845808.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Servlet and Wicket

2011-09-26 Thread manuelbarzi
i would suggest you, hohaeri, to do the migration progressively, by
keeping your servlet-application living with your new
wicket-application, while translating one by one your pages from the
first to the latter, til finally have all your application fully
migrated. if you have correctly done SoC in your current application
(business objects, integration layer, components...) then moving from
your servlet-app to the new wicket-app wouldn't be so painful. if this
is not the case, then "just re-do it" all... probably it may worth it
;-)
.



On Tue, Sep 27, 2011 at 12:37 AM,   wrote:
> Hi..
> I understood what your issue is. Just want to share my experience here.
> I used to convert my struts application to wicket. I found there were no easy 
> way to solve this matter. Since wicket is component based, not rely on 
> servlet to do an action.
> Finally, I ended this matter by recreating all the jsp page to wicket page 
> one by one.
> The html dan css structure were still usable. Just need reform the page with 
> wicket style.
> Other things like form action servlet, link, etc are not much usable except 
> the business logic.
> The way jsp do page templating (e.g. tiles or sitemesh) was also not usable. 
> In wicket we do inheritance or border to do page templating.
> My conclusion, this is not an easy thing to do. But if you really want to, 
> you really need to spent time to reform your presentation. It can be a pain 
> if your project is huge size.
>
> I know I didn't share any solution here, just shared my thoughts.
> Hope others have solution for you.
>
> Cheers,
> Noven
> Sent from my BlackBerry® smartphone from Sinyal Bagus XL, Nyambung 
> Teruuusss...!
>
> -Original Message-
> From: "koha...@gmail.com" 
> Date: Mon, 26 Sep 2011 15:06:42
> To: 
> Reply-To: users@wicket.apache.org
> Subject: Re: Servlet and Wicket
>
> I am asking this question because I have reviewed all the books published on
> Wicket including the recent Wicket Cookbook, I have not seen any examples of
> how you can replace JSP with Wicket. I want to use Wicket in my current
> project but it would be cost prohibitive if I have to discard all the
> Servlet implementation. Now, my question is, how easy would it be to replace
> the JSP code with Wicket code. Or to ask it another way. Is it possible to
> reuse my current Servlet code and integrate it with Wicket for the UI. It
> would help to see examples of how to integrate Servlet code with Wicket.
>
> I hope this helps clearify things a bit.
>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3845548.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Re: Servlet and Wicket

2011-09-26 Thread noven_lie
Hi.. 
I understood what your issue is. Just want to share my experience here. 
I used to convert my struts application to wicket. I found there were no easy 
way to solve this matter. Since wicket is component based, not rely on servlet 
to do an action. 
Finally, I ended this matter by recreating all the jsp page to wicket page one 
by one. 
The html dan css structure were still usable. Just need reform the page with 
wicket style. 
Other things like form action servlet, link, etc are not much usable except the 
business logic.  
The way jsp do page templating (e.g. tiles or sitemesh) was also not usable. In 
wicket we do inheritance or border to do page templating.
My conclusion, this is not an easy thing to do. But if you really want to, you 
really need to spent time to reform your presentation. It can be a pain if your 
project is huge size. 

I know I didn't share any solution here, just shared my thoughts. 
Hope others have solution for you.

Cheers,
Noven
Sent from my BlackBerry® smartphone from Sinyal Bagus XL, Nyambung Teruuusss...!

-Original Message-
From: "koha...@gmail.com" 
Date: Mon, 26 Sep 2011 15:06:42 
To: 
Reply-To: users@wicket.apache.org
Subject: Re: Servlet and Wicket

I am asking this question because I have reviewed all the books published on
Wicket including the recent Wicket Cookbook, I have not seen any examples of
how you can replace JSP with Wicket. I want to use Wicket in my current
project but it would be cost prohibitive if I have to discard all the
Servlet implementation. Now, my question is, how easy would it be to replace
the JSP code with Wicket code. Or to ask it another way. Is it possible to
reuse my current Servlet code and integrate it with Wicket for the UI. It
would help to see examples of how to integrate Servlet code with Wicket.

I hope this helps clearify things a bit.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3845548.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Servlet and Wicket

2011-09-26 Thread Igor Vaynberg
On Mon, Sep 26, 2011 at 3:06 PM, koha...@gmail.com  wrote:
> I am asking this question because I have reviewed all the books published on
> Wicket including the recent Wicket Cookbook, I have not seen any examples of
> how you can replace JSP with Wicket. I want to use Wicket in my current
> project but it would be cost prohibitive if I have to discard all the
> Servlet implementation.

wicket and servlets can live side-by-side. wicket doesnt take over the
url space so servlets and jsps can still be accessed like they used to
be.

> Now, my question is, how easy would it be to replace
> the JSP code with Wicket code. Or to ask it another way. Is it possible to
> reuse my current Servlet code and integrate it with Wicket for the UI. It
> would help to see examples of how to integrate Servlet code with Wicket.

define "integrate"

-igor


>
> I hope this helps clearify things a bit.
>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3845548.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Re: Servlet and Wicket

2011-09-26 Thread koha...@gmail.com
I am asking this question because I have reviewed all the books published on
Wicket including the recent Wicket Cookbook, I have not seen any examples of
how you can replace JSP with Wicket. I want to use Wicket in my current
project but it would be cost prohibitive if I have to discard all the
Servlet implementation. Now, my question is, how easy would it be to replace
the JSP code with Wicket code. Or to ask it another way. Is it possible to
reuse my current Servlet code and integrate it with Wicket for the UI. It
would help to see examples of how to integrate Servlet code with Wicket.

I hope this helps clearify things a bit.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3845548.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Firing JavaScript handler on AJAX panel swap

2011-09-26 Thread Alec Swan
Martin, Wicket.Ajax.doGet() is called when JavaScript is contributed
with response.renderJavascriptReference(script). So, there is no way
for preCallHandlers to distinguish between JavaScript contribution and
user-initiated click.

I would also like to mention that this is not a jQuery issue.

Thanks!

Alec

On Mon, Sep 26, 2011 at 4:02 AM, Emond Papegaaij
 wrote:
> Hi Alec,
>
> If you use WiQuery for your javascript-enabled panels, this is done
> automatically. WiQuery will add the javascript calls in the right places for
> you.
>
> Best regards,
> Emond
>
> On Saturday 24 September 2011 19:58:05 Alec Swan wrote:
>> Hello,
>>
>> We use panel swapping to implement tabbing. The code contributes
>> javascript the head when the panels are swapped using AJAX. Some of
>> our JS scripts register $(document).ready() handlers. However, these
>> handler never fire during panel swap.
>>
>> How can we register our JS handlers so that they fire on AJAX-based panel
>> swap?
>>
>> Thanks,
>>
>> Alec
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Re: Servlet and Wicket

2011-09-26 Thread Igor Vaynberg
you did not ask a specific enough question...

-igor


On Mon, Sep 26, 2011 at 12:00 PM, koha...@gmail.com  wrote:
> We have significant Servlet JSP investment in our major development efforts.
> Now, we want to switch from JSP to Wicket. Because of request dispatching
> and current investment from http to servlet connectivity we want to reuse
> the servlet components and swap out just the JSP with Wicket.
>
> Is there a way to make this work? The investment in Servlet development is
> significant. Therefore we want to reuse them. If cannot, we may have to
> continue with JSP. If someone know how we can integrate Servlet and Wicket
> in the presentation layer please let me know. Your response is very much
> appreciated.
>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3844944.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Servlet and Wicket

2011-09-26 Thread koha...@gmail.com
We have significant Servlet JSP investment in our major development efforts.
Now, we want to switch from JSP to Wicket. Because of request dispatching
and current investment from http to servlet connectivity we want to reuse
the servlet components and swap out just the JSP with Wicket.

Is there a way to make this work? The investment in Servlet development is
significant. Therefore we want to reuse them. If cannot, we may have to
continue with JSP. If someone know how we can integrate Servlet and Wicket
in the presentation layer please let me know. Your response is very much
appreciated.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Servlet-and-Wicket-tp3844944p3844944.html
Sent from the Users forum mailing list archive at Nabble.com.

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



RE: WicketFilter 1.5 ignorePaths - any changes?

2011-09-26 Thread Chris Colman
Doh! That was my bad.

Was building the 1.5 version of our app in a different directory but didn't 
change the docBase in the app's Tomcat config to reflect that new directory so 
it continued to pull unchanged web.xml from the old 1.4 directory

Embarrassed =]

>It should be the same behavior but since this method has been lost and
>re-introduced in 1.5 it may have issues.
>It has test in WicketFilterTest. Extend the test with the failures and
>attach it in a ticket.
>
>On Mon, Sep 26, 2011 at 11:22 AM, Chris Colman
> wrote:
>> Are there any changes to the way the ignorePaths init-param works in
>> 1.5?
>>
>> I have a web.xml that has been working fine in 1.4 with a set of
>> ignorePaths but it appears as though Wicket 1.5 is trying to process
>> some of the requests that it was ignoring in 1.4.
>>
>>                        
>>                                    ignorePaths
>>
>> images/,admin/
>>                        
>>
>> Anyone seen this issue or have I done something else wrong?
>>
>
>
>
>--
>Martin Grigorov
>jWeekend
>Training, Consulting, Development
>http://jWeekend.com
>
>-
>To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>For additional commands, e-mail: users-h...@wicket.apache.org


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



Re: How to handle errors in RequestCycle.onEndRequest

2011-09-26 Thread Christian Huber
as i suspected ;-) i have been using onRuntimeException already but 
without onRequestHandlerExecuted this is not enough.


well, off to migration it is then :-)


The Sanity Resort 

Am 26.09.2011 18:28, schrieb Igor Vaynberg:

1.4.x has onRuntimeException() but it has no callback for when the
request handler has executed...

-igor

On Sun, Sep 25, 2011 at 2:20 PM, Christian Huber  wrote:

Sorry for bugging again, but I just saw that IRequestCycleListener is not
available in wicket 1.4.x. Is there an alternative other than switching to
1.5.x?

The Sanity Resort

Am 24.09.2011 17:18, schrieb Igor Vaynberg:

use the onRequestHandlerExecuted() to commit the transaction and
onException() to roll it back. these are both in
IRequestCycleListener.

-igor

On Mon, Sep 19, 2011 at 10:50 AM, Christian Huber
  wrote:

Hi all,

I just noticed that exceptions occuring in onEndRequest of a RequestCycle
somehow do not reflect on the respone page.

I am using an AjaxFallbackButton and the OSIV pattern and thus commit my
database changes in onEndRequest, now if an exception occurs here I do
get a
log entry but I cannot get my application to display the corresponding
error
to the user.

Adding a message to the feedback panel does not help as the message gets
displayed on the following request but not the current one. I also tried
using various AbortExceptions like RedirectToUrlException,
RestartResponseException or AbortWithWebErrorCodeException. This did
improve
the situation as far as the request did get aborted but there is still no
visual display of the error.

Setting the ResponsePage directly and/or setting redirect to true did not
change anything.

This sounds like a common problem and so I guess there is an easy
solution
to it, but I just don't get it right now, so any pointers are welcome.

Thanks, Chris

--
The Sanity Resort


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


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



Wicket 1.4 redirects to root path

2011-09-26 Thread Bruno Borges
A Wicket 1.4.17 application with its Filter mapped to /foo/* is being
redirect to root path after a form submit.

Does anyone have any idea on what can be going wrong?

Thanks

*Bruno Borges*
(21) 7672-7099
*www.brunoborges.com*


Re: creating a textarea with a radiobutton using Listview

2011-09-26 Thread wholalotta
Thanks a lot. I wish I have seen the obvious solution by myself but anyway
everything is clear now..I should have iterated the Listview not the list
item. My plan was iterating the list component and updating the model value
in it. But you are right, iterating "item" wont give me the all the item
list. And you updated "data" which is the model of Listview..You accessed
the model value of Listview directly.
I also noticed that you didnt set "inputForm.setOutputMarkupId(true)" but it
didnt give any error while rendering page. How this can be possible? And
also using ajaxcheckbox is the same like adding  OnChangeAjaxBehavior onto a
standart checkbox am i right?


 AjaxCheckBox a = new AjaxCheckBox("checkbox", new
PropertyModel(wrapper, "selected")) { 
 
protected void onUpdate(AjaxRequestTarget
target) {   
 if (wrapper.getSelected()) { 
 for (NameWrapper entity : data) { 
 if
(!entity.equals(wrapper)) { 

entity.setSelected(Boolean.FALSE); 
 } 
 } 
 } 
 target.addComponent(inputForm);
} 
}; 
item.add(a);

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/creating-a-textarea-with-a-radiobutton-using-Listview-tp3829602p3844783.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: How to handle errors in RequestCycle.onEndRequest

2011-09-26 Thread Igor Vaynberg
1.4.x has onRuntimeException() but it has no callback for when the
request handler has executed...

-igor

On Sun, Sep 25, 2011 at 2:20 PM, Christian Huber  wrote:
> Sorry for bugging again, but I just saw that IRequestCycleListener is not
> available in wicket 1.4.x. Is there an alternative other than switching to
> 1.5.x?
>
> The Sanity Resort 
>
> Am 24.09.2011 17:18, schrieb Igor Vaynberg:
>>
>> use the onRequestHandlerExecuted() to commit the transaction and
>> onException() to roll it back. these are both in
>> IRequestCycleListener.
>>
>> -igor
>>
>> On Mon, Sep 19, 2011 at 10:50 AM, Christian Huber
>>  wrote:
>>>
>>> Hi all,
>>>
>>> I just noticed that exceptions occuring in onEndRequest of a RequestCycle
>>> somehow do not reflect on the respone page.
>>>
>>> I am using an AjaxFallbackButton and the OSIV pattern and thus commit my
>>> database changes in onEndRequest, now if an exception occurs here I do
>>> get a
>>> log entry but I cannot get my application to display the corresponding
>>> error
>>> to the user.
>>>
>>> Adding a message to the feedback panel does not help as the message gets
>>> displayed on the following request but not the current one. I also tried
>>> using various AbortExceptions like RedirectToUrlException,
>>> RestartResponseException or AbortWithWebErrorCodeException. This did
>>> improve
>>> the situation as far as the request did get aborted but there is still no
>>> visual display of the error.
>>>
>>> Setting the ResponsePage directly and/or setting redirect to true did not
>>> change anything.
>>>
>>> This sounds like a common problem and so I guess there is an easy
>>> solution
>>> to it, but I just don't get it right now, so any pointers are welcome.
>>>
>>> Thanks, Chris
>>>
>>> --
>>> The Sanity Resort
>>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>

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



Re: set content type of response in wicket 1.5

2011-09-26 Thread Martin A
Ok, so it's been moved to WebResponse... I should have figured that out :)

Thanks

On Mon, Sep 26, 2011 at 5:24 PM, Martin Grigorov wrote:

> org.apache.wicket.request.http.WebResponse.setContentType(String)
>
> On Mon, Sep 26, 2011 at 4:21 PM, Martin A  wrote:
> > Yes, sorry, I meant Response, as it says in the title.
> >
> > Thanks
> >
> > On Mon, Sep 26, 2011 at 5:19 PM, Martin Grigorov  >wrote:
> >
> >> I guess you mean Response because you can't write in the Request
> >>
> >> On Mon, Sep 26, 2011 at 4:14 PM, Martin A  wrote:
> >> > Hello,
> >> >
> >> > In Wicket 1.4 and before that there was a method setContentType(String
> >> str)
> >> > in the class Request. What's its equivalent in wicket 1.5?
> >> >
> >> > Thanks
> >> >
> >>
> >>
> >>
> >> --
> >> Martin Grigorov
> >> jWeekend
> >> Training, Consulting, Development
> >> http://jWeekend.com
> >>
> >> -
> >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> >> For additional commands, e-mail: users-h...@wicket.apache.org
> >>
> >>
> >
>
>
>
> --
> Martin Grigorov
> jWeekend
> Training, Consulting, Development
> http://jWeekend.com
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: set content type of response in wicket 1.5

2011-09-26 Thread Martin Grigorov
org.apache.wicket.request.http.WebResponse.setContentType(String)

On Mon, Sep 26, 2011 at 4:21 PM, Martin A  wrote:
> Yes, sorry, I meant Response, as it says in the title.
>
> Thanks
>
> On Mon, Sep 26, 2011 at 5:19 PM, Martin Grigorov wrote:
>
>> I guess you mean Response because you can't write in the Request
>>
>> On Mon, Sep 26, 2011 at 4:14 PM, Martin A  wrote:
>> > Hello,
>> >
>> > In Wicket 1.4 and before that there was a method setContentType(String
>> str)
>> > in the class Request. What's its equivalent in wicket 1.5?
>> >
>> > Thanks
>> >
>>
>>
>>
>> --
>> Martin Grigorov
>> jWeekend
>> Training, Consulting, Development
>> http://jWeekend.com
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

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



Re: set content type of response in wicket 1.5

2011-09-26 Thread Martin A
Yes, sorry, I meant Response, as it says in the title.

Thanks

On Mon, Sep 26, 2011 at 5:19 PM, Martin Grigorov wrote:

> I guess you mean Response because you can't write in the Request
>
> On Mon, Sep 26, 2011 at 4:14 PM, Martin A  wrote:
> > Hello,
> >
> > In Wicket 1.4 and before that there was a method setContentType(String
> str)
> > in the class Request. What's its equivalent in wicket 1.5?
> >
> > Thanks
> >
>
>
>
> --
> Martin Grigorov
> jWeekend
> Training, Consulting, Development
> http://jWeekend.com
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: set content type of response in wicket 1.5

2011-09-26 Thread Martin Grigorov
I guess you mean Response because you can't write in the Request

On Mon, Sep 26, 2011 at 4:14 PM, Martin A  wrote:
> Hello,
>
> In Wicket 1.4 and before that there was a method setContentType(String str)
> in the class Request. What's its equivalent in wicket 1.5?
>
> Thanks
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

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



set content type of response in wicket 1.5

2011-09-26 Thread Martin A
Hello,

In Wicket 1.4 and before that there was a method setContentType(String str)
in the class Request. What's its equivalent in wicket 1.5?

Thanks


Re: creating a textarea with a radiobutton using Listview

2011-09-26 Thread manuelbarzi
that iterator you added has no much sense, as it represents only an
item on the list, but not the list itself.
moreover you don't need modifying components, but updating their
models, as mentioned in mail before (may you study wicket models a bit
more... see https://cwiki.apache.org/WICKET/working-with-wicket-models.html)

may you apply OnChangeAjaxBehaviour on each checkbox, instead of
adding a CheckGroup.

here's the code before, modified to work as you need, deselecting
other checkboxes when current one is selected:

[2]

java:


public class CheckBoxListPage extends WebPage {

private Form inputForm;

public CheckBoxListPage()
{
final FeedbackPanel feedback = new FeedbackPanel("feedback");
add(feedback);
add(inputForm = new InputForm("inputForm"));
}

/** form for processing the input. */
private class InputForm extends Form
{
// holds NameWrapper elements
private List data;

public InputForm(String name)
{
super(name);

// add some dummy data
data = new ArrayList();
data.add(new NameWrapper("one"));
data.add(new NameWrapper("two"));
data.add(new NameWrapper("three"));
data.add(new NameWrapper("four"));
// add a nested list view; as the list is nested in the 
form, the form will
// update all FormComponent childs automatically.
final ListView listView = new
ListView("list", data)
{

protected void 
populateItem(ListItem item)
{
final NameWrapper wrapper = 
(NameWrapper)item.getModelObject();
item.add(new Label("name", 
wrapper.getName()));
final CheckBox checkBox = new 
CheckBox("check", new
PropertyModel(wrapper, "selected"));
item.add(checkBox);
checkBox.add(new OnChangeAjaxBehavior() 
{

@Override
protected void 
onUpdate(AjaxRequestTarget target) {


if 
(wrapper.getSelected()) {
for 
(NameWrapper entity : data) {
if 
(!entity.equals(wrapper)) {

entity.setSelected(Boolean.FALSE);
}
}
}

target.addComponent(inputForm);
}

});
}
};
listView.setReuseItems(true);
add(listView);
}

public void onSubmit()
{
info("data: " + data); // print current contents
}
}


On Mon, Sep 26, 2011 at 12:06 PM, wholalotta  wrote:
> I tried the following but couldnt get into "onUpdate" method while debugging.
> I need to use checkgroup to be able to use
> AjaxFormChoiceComponentUpdatingBehavior. So I created a checkgroup and added
> the checkboxes into it. So I guess in each iteration I am creating one text
> area, one check group and one checkbox that is attached to that checkgroup.
> What I am trying to do is when I select a checkbox, I want to re-render only
> the checkboxes by iterating the item list one by one. But it seems if I do
> this I need to add ajaxbehaviour on to listview?? I think what I am trying
> to do in here is a little bit tricky and this is not Listview is created for
> am i right? I am definitely stucked. If I dont use Listview, I need to do
> this by putting more lines of code and I dont want to do that.
>
>                ListView listView = new ListView("list", data)
>                {
>
>                    @Override
>                    protected void populateItem(final ListItem item) {
>                            NameWrapper wrapper =
> (NameWrapper)item.getModelObject();
>                            item.add(new TextArea("name", new
> Proper

Re: [Migration 1.5] Howto configure HttpsMapper to ignore https protocol by configuration?

2011-09-26 Thread Mike Mander

Thanks Martin,

Problem solved. Instead of implementing something i've configured the 
mapper:

if (_httpsPort > -1) {
setRootRequestMapper(new 
HttpsMapper(getRootRequestMapper(), new HttpsConfig(_httpPort, 
_httpsPort)));

}

:-)
That is simple and no need to copy code :-)

Thanks for help
Mike

Can't you just return the passed IRequestHandler/Url in
mapHandler/mapRequest() methods if the https port is -1 ?
No need to use HttpsRequestChecker at all.

On Mon, Sep 26, 2011 at 11:17 AM, Mike Mander  wrote:

Thanks Martin,

Overriding / implementing my own mapper would be an option if i could use
the HttpsRequestChecker.
But it's package private (1.5.0).

But thinking about that again lead me to another option =>  set the
https_port in config.
setRootRequestMapper(new HttpsMapper(getRootRequestMapper(), new
HttpsConfig(_httpPort, _httpsPort == -1 ? _httpPort : _httpsPort)));

But now i have still the problem with setting the protocol of url.

Mike


Just override
org.apache.wicket.protocol.https.HttpsMapper.mapRequest(Request)
and/or
org.apache.wicket.protocol.https.HttpsMapper.mapHandler(IRequestHandler)
and do whatever you need.
This class is very simple. You can even create your own.

On Mon, Sep 26, 2011 at 8:39 AM, Mike Manderwrote:

Hi,

on my integration server there is another application using the ssl port
(certificate etc.). I can't disable it so far.
Because ssl certificate can only be used for one app, i disabled ssl by
configuration for my app with wicket 1.4.x.
I configured the https port to -1 and so ssl (with HttpsRequired
annotation)
was ignored and http was used instead.

WicketApplication.java

@Override
protected IRequestCycleProcessor newRequestCycleProcessor() {
HttpsConfig config = new HttpsConfig(_httpPort, _httpsPort);
return new HttpsRequestCycleProcessor(config) {

@Override
protected IRequestTarget checkSecureIncoming(IRequestTarget
target) {
if (_httpsPort == -1) {
return target;
}
return super.checkSecureIncoming(target);
}

@Override
protected IRequestTarget checkSecureOutgoing(IRequestTarget
target) {
if (_httpsPort == -1) {
return target;
}
return super.checkSecureOutgoing(target);
}
};
}



But with 1.5 the HttpsMapper is not configurable this way. Extending
HttpsMapper wasn't working because of the  maphandler implementation. Is
there another way to solve this usecase?

Thanks
Mike

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






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








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



Re: creating a textarea with a radiobutton using Listview

2011-09-26 Thread wholalotta
I tried the following but couldnt get into "onUpdate" method while debugging.
I need to use checkgroup to be able to use
AjaxFormChoiceComponentUpdatingBehavior. So I created a checkgroup and added
the checkboxes into it. So I guess in each iteration I am creating one text
area, one check group and one checkbox that is attached to that checkgroup.
What I am trying to do is when I select a checkbox, I want to re-render only
the checkboxes by iterating the item list one by one. But it seems if I do
this I need to add ajaxbehaviour on to listview?? I think what I am trying
to do in here is a little bit tricky and this is not Listview is created for
am i right? I am definitely stucked. If I dont use Listview, I need to do
this by putting more lines of code and I dont want to do that.

ListView listView = new ListView("list", data) 
{ 

@Override 
protected void populateItem(final ListItem item) { 
NameWrapper wrapper =
(NameWrapper)item.getModelObject(); 
item.add(new TextArea("name", new
PropertyModel(wrapper, "name"))); 
final CheckGroup checkgroup = new CheckGroup
("checkgroup", new PropertyModel(wrapper, "selected"));
item.add(checkgroup);
CheckBox check = new CheckBox("checkbox",new
Model());
checkgroup.setOutputMarkupId(true);
checkgroup.add(check);
checkgroup.add(new
AjaxFormChoiceComponentUpdatingBehavior() { 
@Override 
protected void onUpdate(AjaxRequestTarget
target) { 
info("We are here");
for (Iterator iter = item.iterator();
iter.hasNext();) {
   
// FIND THE SELECTED ONE and DE-SELECT
the OTHER CHECKBOXES in the list
}
target.addComponent(checkgroup);
} 
}); 
} 
}; 
listView.setReuseItems(true); 
add(listView); 

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/creating-a-textarea-with-a-radiobutton-using-Listview-tp3829602p3843288.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Firing JavaScript handler on AJAX panel swap

2011-09-26 Thread Emond Papegaaij
Hi Alec,

If you use WiQuery for your javascript-enabled panels, this is done 
automatically. WiQuery will add the javascript calls in the right places for 
you.

Best regards,
Emond

On Saturday 24 September 2011 19:58:05 Alec Swan wrote:
> Hello,
> 
> We use panel swapping to implement tabbing. The code contributes
> javascript the head when the panels are swapped using AJAX. Some of
> our JS scripts register $(document).ready() handlers. However, these
> handler never fire during panel swap.
> 
> How can we register our JS handlers so that they fire on AJAX-based panel
> swap?
> 
> Thanks,
> 
> Alec
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org

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



Re: WicketFilter 1.5 ignorePaths - any changes?

2011-09-26 Thread Martin Grigorov
It should be the same behavior but since this method has been lost and
re-introduced in 1.5 it may have issues.
It has test in WicketFilterTest. Extend the test with the failures and
attach it in a ticket.

On Mon, Sep 26, 2011 at 11:22 AM, Chris Colman
 wrote:
> Are there any changes to the way the ignorePaths init-param works in
> 1.5?
>
> I have a web.xml that has been working fine in 1.4 with a set of
> ignorePaths but it appears as though Wicket 1.5 is trying to process
> some of the requests that it was ignoring in 1.4.
>
>                        
>                                    ignorePaths
>
> images/,admin/
>                        
>
> Anyone seen this issue or have I done something else wrong?
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

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



WicketFilter 1.5 ignorePaths - any changes?

2011-09-26 Thread Chris Colman
Are there any changes to the way the ignorePaths init-param works in
1.5?
 
I have a web.xml that has been working fine in 1.4 with a set of
ignorePaths but it appears as though Wicket 1.5 is trying to process
some of the requests that it was ignoring in 1.4.
 

ignorePaths
 
images/,admin/

 
Anyone seen this issue or have I done something else wrong?


Re: [Migration 1.5] Howto configure HttpsMapper to ignore https protocol by configuration?

2011-09-26 Thread Martin Grigorov
Can't you just return the passed IRequestHandler/Url in
mapHandler/mapRequest() methods if the https port is -1 ?
No need to use HttpsRequestChecker at all.

On Mon, Sep 26, 2011 at 11:17 AM, Mike Mander  wrote:
> Thanks Martin,
>
> Overriding / implementing my own mapper would be an option if i could use
> the HttpsRequestChecker.
> But it's package private (1.5.0).
>
> But thinking about that again lead me to another option => set the
> https_port in config.
> setRootRequestMapper(new HttpsMapper(getRootRequestMapper(), new
> HttpsConfig(_httpPort, _httpsPort == -1 ? _httpPort : _httpsPort)));
>
> But now i have still the problem with setting the protocol of url.
>
> Mike
>
>> Just override
>> org.apache.wicket.protocol.https.HttpsMapper.mapRequest(Request)
>> and/or
>> org.apache.wicket.protocol.https.HttpsMapper.mapHandler(IRequestHandler)
>> and do whatever you need.
>> This class is very simple. You can even create your own.
>>
>> On Mon, Sep 26, 2011 at 8:39 AM, Mike Mander  wrote:
>>>
>>> Hi,
>>>
>>> on my integration server there is another application using the ssl port
>>> (certificate etc.). I can't disable it so far.
>>> Because ssl certificate can only be used for one app, i disabled ssl by
>>> configuration for my app with wicket 1.4.x.
>>> I configured the https port to -1 and so ssl (with HttpsRequired
>>> annotation)
>>> was ignored and http was used instead.
>>>
>>> WicketApplication.java
>>> 
>>>    @Override
>>>    protected IRequestCycleProcessor newRequestCycleProcessor() {
>>>        HttpsConfig config = new HttpsConfig(_httpPort, _httpsPort);
>>>        return new HttpsRequestCycleProcessor(config) {
>>>
>>>            @Override
>>>            protected IRequestTarget checkSecureIncoming(IRequestTarget
>>> target) {
>>>                if (_httpsPort == -1) {
>>>                    return target;
>>>                }
>>>                return super.checkSecureIncoming(target);
>>>            }
>>>
>>>            @Override
>>>            protected IRequestTarget checkSecureOutgoing(IRequestTarget
>>> target) {
>>>                if (_httpsPort == -1) {
>>>                    return target;
>>>                }
>>>                return super.checkSecureOutgoing(target);
>>>            }
>>>        };
>>>    }
>>>
>>> 
>>>
>>> But with 1.5 the HttpsMapper is not configurable this way. Extending
>>> HttpsMapper wasn't working because of the  maphandler implementation. Is
>>> there another way to solve this usecase?
>>>
>>> Thanks
>>> Mike
>>>
>>> -
>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>
>>>
>>
>>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

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



Re: [Migration 1.5] Howto configure HttpsMapper to ignore https protocol by configuration?

2011-09-26 Thread Mike Mander

Thanks Martin,

Overriding / implementing my own mapper would be an option if i could 
use the HttpsRequestChecker.

But it's package private (1.5.0).

But thinking about that again lead me to another option => set the 
https_port in config.
setRootRequestMapper(new HttpsMapper(getRootRequestMapper(), new 
HttpsConfig(_httpPort, _httpsPort == -1 ? _httpPort : _httpsPort)));


But now i have still the problem with setting the protocol of url.

Mike


Just override org.apache.wicket.protocol.https.HttpsMapper.mapRequest(Request)
and/or org.apache.wicket.protocol.https.HttpsMapper.mapHandler(IRequestHandler)
and do whatever you need.
This class is very simple. You can even create your own.

On Mon, Sep 26, 2011 at 8:39 AM, Mike Mander  wrote:

Hi,

on my integration server there is another application using the ssl port
(certificate etc.). I can't disable it so far.
Because ssl certificate can only be used for one app, i disabled ssl by
configuration for my app with wicket 1.4.x.
I configured the https port to -1 and so ssl (with HttpsRequired annotation)
was ignored and http was used instead.

WicketApplication.java

@Override
protected IRequestCycleProcessor newRequestCycleProcessor() {
HttpsConfig config = new HttpsConfig(_httpPort, _httpsPort);
return new HttpsRequestCycleProcessor(config) {

@Override
protected IRequestTarget checkSecureIncoming(IRequestTarget
target) {
if (_httpsPort == -1) {
return target;
}
return super.checkSecureIncoming(target);
}

@Override
protected IRequestTarget checkSecureOutgoing(IRequestTarget
target) {
if (_httpsPort == -1) {
return target;
}
return super.checkSecureOutgoing(target);
}
};
}



But with 1.5 the HttpsMapper is not configurable this way. Extending
HttpsMapper wasn't working because of the  maphandler implementation. Is
there another way to solve this usecase?

Thanks
Mike

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








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



Re: replace panel in dialog box

2011-09-26 Thread pragya.rawal
Hi,

Any further thoughts on this issue ?

Thanks

-
Pragya
http://pragyarawal.co.cc
--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/replace-panel-in-dialog-box-tp3640377p3843188.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: DecimalFormatLabel (proposed)

2011-09-26 Thread Yves-Marie LAINÉ
I agree with you.

Yves-Marie

2011/9/25 Pranav kacholia 

> One way or the other, i think Wicket needs a label of that sort.
> There are too many places where i have to display currency. It should have
> something inbuilt that allows us to display formatted strings and numbers
> (a
> label)
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/DecimalFormatLabel-proposed-tp3834813p3840944.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
Yves-Marie LAINÉ


Re: Firing JavaScript handler on AJAX panel swap

2011-09-26 Thread Martin Grigorov
On Sun, Sep 25, 2011 at 11:30 PM, Alec Swan  wrote:
> It would be nice if Wicket JavaScript API supported registration of
> handlers for user-initiated AJAX events, such as clicking on a link,
> separately from code-initiated AJAX events, such as contributing a
> JavaScript script to head. The current
> Wicket.Ajax.registerPreCallHandler does not support this distinction.
Can you give more details ?

Wicket.Ajax.invokePreCallHandlers(); is called from
Wicket.Ajax.doGet() so it will be called for all Wicket.Ajax.** calls.
If you use JQuery.ajax() then it wont be called.
>
> Thoughts?
>
> Thanks,
>
> Alec
>
> On Sat, Sep 24, 2011 at 9:04 PM, Alec Swan  wrote:
>> Hello,
>>
>> Our JavaScript code shows a busy sign/progress bar from a handler
>> registered with Wicket.Ajax.registerPreCallHandler(showBusysign).
>>
>> However, now that we contribute JavaScript during panel swap the busy
>> sign flickers twice - once when the panels are swapped using AJAX and
>> the second time when JavaScript is contributed. Is there a way to
>> distinguish between these two scenarios on the client side so that we
>> can avoid displaying busy sign when JS is being contributed?
>>
>> Thanks,
>>
>> Alec
>>
>> On Sat, Sep 24, 2011 at 1:52 PM, Alec Swan  wrote:
>>> My problem was that I was trying to call
>>> Wicket.Event.addDomReadyEvent() from the script that was loaded by
>>> response.renderJavascriptReference(). And for some reason the
>>> registration code was never getting called.
>>>
>>> If I have a JS script which contains function declarations and inline
>>> function calls, does Wicket handle them differently? In other words,
>>> does Wicket inject function declarations differently than inline
>>> method calls?
>>>
>>> Thanks,
>>>
>>> Alec
>>>
>>> On Sat, Sep 24, 2011 at 1:05 PM, Igor Vaynberg  
>>> wrote:
 maybe you are registering them too late..

 -igor

 On Sat, Sep 24, 2011 at 12:04 PM, Alec Swan  wrote:
> I found this thread
> http://apache-wicket.1842946.n4.nabble.com/correct-way-to-call-necessary-javascript-initialization-when-a-component-is-added-via-ajax-td1875918.html
> where there was a recommendation to use
> Wicket.Event.addDomReadyEvent(), but I can't get handlers registered
> this way to fire on panel swap. Any ideas why?
>
> On Sat, Sep 24, 2011 at 12:52 PM, Igor Vaynberg  
> wrote:
>> we dont do that yet, but makes sense. you are welcome to attach a 
>> patch...
>>
>> -igor
>>
>>
>> On Sat, Sep 24, 2011 at 11:51 AM, Alec Swan  wrote:
>>> Thanks. Is there a way to do this using JavaScript only? Maybe
>>> register for some JavaScript event that Wicket fires when DOM is
>>> ready?
>>>
>>> On Sat, Sep 24, 2011 at 12:42 PM, Igor Vaynberg 
>>>  wrote:
 use ajaxrequesttarget.renderondomreadyjavascript() instead of jquery's 
 ready()

 -igor

 On Sat, Sep 24, 2011 at 10:58 AM, Alec Swan  wrote:
> Hello,
>
> We use panel swapping to implement tabbing. The code contributes
> javascript the head when the panels are swapped using AJAX. Some of
> our JS scripts register $(document).ready() handlers. However, these
> handler never fire during panel swap.
>
> How can we register our JS handlers so that they fire on AJAX-based 
> panel swap?
>
> Thanks,
>
> Alec
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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


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

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


>>>
>>
>
> -
> To unsubscribe, e-mail: users-unsu

Re: [Migration 1.5] Howto configure HttpsMapper to ignore https protocol by configuration?

2011-09-26 Thread Martin Grigorov
Just override org.apache.wicket.protocol.https.HttpsMapper.mapRequest(Request)
and/or org.apache.wicket.protocol.https.HttpsMapper.mapHandler(IRequestHandler)
and do whatever you need.
This class is very simple. You can even create your own.

On Mon, Sep 26, 2011 at 8:39 AM, Mike Mander  wrote:
> Hi,
>
> on my integration server there is another application using the ssl port
> (certificate etc.). I can't disable it so far.
> Because ssl certificate can only be used for one app, i disabled ssl by
> configuration for my app with wicket 1.4.x.
> I configured the https port to -1 and so ssl (with HttpsRequired annotation)
> was ignored and http was used instead.
>
> WicketApplication.java
> 
>    @Override
>    protected IRequestCycleProcessor newRequestCycleProcessor() {
>        HttpsConfig config = new HttpsConfig(_httpPort, _httpsPort);
>        return new HttpsRequestCycleProcessor(config) {
>
>            @Override
>            protected IRequestTarget checkSecureIncoming(IRequestTarget
> target) {
>                if (_httpsPort == -1) {
>                    return target;
>                }
>                return super.checkSecureIncoming(target);
>            }
>
>            @Override
>            protected IRequestTarget checkSecureOutgoing(IRequestTarget
> target) {
>                if (_httpsPort == -1) {
>                    return target;
>                }
>                return super.checkSecureOutgoing(target);
>            }
>        };
>    }
>
> 
>
> But with 1.5 the HttpsMapper is not configurable this way. Extending
> HttpsMapper wasn't working because of the  maphandler implementation. Is
> there another way to solve this usecase?
>
> Thanks
> Mike
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

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