Re: Slow rendering

2012-02-16 Thread Christian Huber
Hi Jürgen, I just had a quick glance at the Component and MarkupContainer classes and if I am not mistaken you should be able to override onRender() and onComponentTag() which would give you a few more measuring points and maybe more pointers on where to look further. HTH, Christian The

Re: Could not locate error message for component: ..

2011-12-29 Thread Christian Huber
Hi, i assume the string isim 3 karakterden büyük olmalı is the error message you want to display. You have two options here, first use ValidationError#setMessage instead of addMessageKey. The later considers it's argument being a message key to be looked up from a properties file. The

Re: Using JNDI from Jetty/Start.java

2011-12-27 Thread Christian Huber
The server complains about a missing value for jndi context factory. Where do you define that value? The Sanity Resort http://sanityresort.blogspot.com/ Am 27.12.2011 19:41, schrieb armhold: Has anyone got a JNDI config that works with Start.java under Wicket 1.5 (and therefore Jetty 7.5)?

Re: How to handle errors in RequestCycle.onEndRequest

2011-10-16 Thread Christian Huber
was already written to response! throwing the exception directly in the homepage constuctor got me redirected to the error page as expected. would you need a new quickstart for this? The Sanity Resorthttp://sanityresort.blogspot.com/ Am 01.10.2011 17:54, schrieb Christian Huber: quickstart

Re: What is the right way to identify the second login for the same user?

2011-10-03 Thread Christian Huber
I might be wrong, but this does not seem like a Wicket related problem. Here a spontaneous idea what I would try: To track sessions of a user I would try to use a database table that associates sessions with users and a boolean flag isvalid. A new session would have to create an entry in that

Re: Crossreferencing wicket internationalization

2011-10-02 Thread Christian Huber
You can use a MapVariableInterpolator to replace the variable with it's label value programmatically, e.g. resolve all nested variables using a resolver (or Component#getString) put them as values into a map with the variable name as key. String label = getString(link_label);

Re: How to handle errors in RequestCycle.onEndRequest

2011-10-01 Thread Christian Huber
Hi again, unfortunately my problem still persists. After migrating to 1.5.1 and putting my commit code into onRequestHandlerExecuted() the error messages generated there are still not propagated to the rendered response page. But instead I now get the following error message: ERROR -

Re: How to handle errors in RequestCycle.onEndRequest

2011-10-01 Thread Christian Huber
quickstart created and added to https://issues.apache.org/jira/browse/WICKET-4103 this quickstart does not behave exactly like my application but the primary problem about messages not being displayed is reproducable. please let me know if i can provide any further information and thank you

Re: How to handle errors in RequestCycle.onEndRequest

2011-10-01 Thread Christian Huber
://sanityresort.blogspot.com/ Am 01.10.2011 17:54, schrieb Christian Huber: quickstart created and added to https://issues.apache.org/jira/browse/WICKET-4103 this quickstart does not behave exactly like my application but the primary problem about messages not being displayed is reproducable. please let me

Re: How to handle errors in RequestCycle.onEndRequest

2011-09-27 Thread Christian Huber
I was thinking about something like that too, but this does look like a dangerous task. And I think in the long run migrating to 1.5.0 is a better solution. The Sanity Resort http://sanityresort.blogspot.com/ Am 27.09.2011 07:50, schrieb Hans Lesmeister 2: Hi, maybe you can override

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 http://sanityresort.blogspot.com/ Am 26.09.2011 18:28, schrieb Igor Vaynberg: 1.4.x has onRuntimeException() but

Re: How to handle errors in RequestCycle.onEndRequest

2011-09-25 Thread Christian Huber
Hi Igor, once more thanks for your help. I 'll try that and see how it works out :-) Cheers, Chris The Sanity Resort http://sanityresort.blogspot.com/ Am 24.09.2011 17:18, schrieb Igor Vaynberg: use the onRequestHandlerExecuted() to commit the transaction and onException() to roll it back.

Re: How to handle errors in RequestCycle.onEndRequest

2011-09-25 Thread Christian Huber
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 http://sanityresort.blogspot.com/ Am 24.09.2011 17:18, schrieb Igor Vaynberg: use the onRequestHandlerExecuted() to

Re: How to handle errors in RequestCycle.onEndRequest

2011-09-24 Thread Christian Huber
Hi again, sorry for reposting, but as I am still struggling with this I thought I try bumping this thread. Any hints would be very welcome. Cheers, Chris The Sanity Resort http://sanityresort.blogspot.com/ Am 19.09.2011 19:50, schrieb Christian Huber: Hi all, I just noticed

Re: How to handle errors in RequestCycle.onEndRequest

2011-09-24 Thread Christian Huber
://sanityresort.blogspot.com/ Am 19.09.2011 19:50, schrieb Christian Huber: 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

Re: Footnote-Support

2011-09-23 Thread Christian Huber
Hi again, for those who might be interessted I just wanted to let you know that I now have a working footnote support implementation. The details can be found here http://sanityresort.blogspot.com/2011/09/adding-footnote-support-to-wicket.html (another chance for shameless blog advertising

Re: Arabic characters not appearing correctly from .properties file

2011-09-20 Thread Christian Huber
Just a short addition, the resource bundle editor plugin for eclipse is great for handling .properties files with UTF-8 characters. The files are stored with ISO encoding and UTF-8 characters are escaped correctly while you can use the unescaped in the editor. The Sanity Resort

Re: Arabic characters not appearing correctly from .properties file

2011-09-20 Thread Christian Huber
Am 20.09.2011 14:31, schrieb Martin Grigorov: On Tue, Sep 20, 2011 at 3:26 PM, Christian Huberhub...@butterbrot.org wrote: Just a short addition, the resource bundle editor plugin for eclipse is great for handling .properties files with UTF-8 characters. The files are stored with ISO encoding

Re: Footnote-Support

2011-09-20 Thread Christian Huber
Well, after about two days I finally got it working ;-) I'll try to scratch together a blog post in the next days with the details :-) The Sanity Resort http://sanityresort.blogspot.com/ Am 19.09.2011 16:41, schrieb Dan Retzlaff: I see now. Forget the behavior approach. :) How about keeping

Re: Footnote-Support

2011-09-19 Thread Christian Huber
Hi Dan, thanks for your answer. To be a bit more clear about what I want, I would like (spoken simplified) to add a footenote to a label like Some text sup1/sup and automatically have the footbnote text appear at the bottom of the corresponding page. Right now I have a Label subclass to do

How to handle errors in RequestCycle.onEndRequest

2011-09-19 Thread Christian Huber
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

Footnote-Support

2011-09-18 Thread Christian Huber
Hi all, I was wondering if there is something like a footnote component/behavior or similar. A mechanism that allows you to easily add a footnote to a label and the corresponding footnote text to one of it's parents in a generic way. I know I could just add a footnote to a label and another

Re: Know if FileUploadField has value set before its parent form is submitted and file gets uploaded

2011-09-04 Thread Christian Huber
Not sure if I completely understand what you want to do but as far as I do I guess the only way to do that is using java script. You could add a java script validation routine to the submit buttons onclick handler that aborts submission when the input field has no value. Another approach

Create Url for Application Homepage

2011-08-24 Thread Christian Huber
Hi, the method Component#urlFor(Class pageClass, PageParameters parameters) allows you to create an application relative link that could be used as dynamic links or stored in a database to be accessed later. Now I noticed that links created for the page set as the applications HomePage the

Re: Create Url for Application Homepage

2011-08-24 Thread Christian Huber
Aaaahh.. cool. Works great. Thanks :-) The Sanity Resort http://sanityresort.blogspot.com/ Am 24.08.2011 21:44, schrieb Martin Grigorov: mount your home page for HomePage1: /home1 for HomePage2: /home2 voila! On Wed, Aug 24, 2011 at 10:28 PM, Christian Huberhub...@butterbrot.org wrote: Hi,

Sorting Feedback Messages

2011-08-23 Thread Christian Huber
Hi, I was wondering if there is a way to have feedback messages show up in certain order. Like, when you have multiple messages for the user you might want to have the most general one (e.g. success/failure) at the top and other detail messages shown below. From what I have seen so far it

Re: Sorting Feedback Messages

2011-08-23 Thread Christian Huber
Yes, as i wrote this would be the way to impose a custom sorting on messages but at the moment the FilterMessage class does not provide dedicated fields that could be used for a sorting metric. So i was wondering if there are plans to provide such a thing or if we will be bound to incooperate

Include Tag Resolver

2011-08-10 Thread Christian Huber
Hi all, maybe someone might find this useful. I created a tag resolver to allow include components to be used in the same way as label components with the wicket:message tag. With this resolver you can use a tag like e.g. wicket:include file=path/to/file/ to include a file into a page. It is

Re: on the fly components

2011-07-31 Thread Christian Huber
Hi, this is just a wild guess but in your code you have line that calls item.remove(listChoice); under certain conditions and the listChoice instance is bound to the category identifier which does not seem right to me. As far as I understand ListViews the associated markup block is created

Re: Non-Submit Button Not Getting Called from Form

2011-07-30 Thread Christian Huber
Hi! Try setting the cancel button's type to submit instead of button, then the onSubmit method should be called. Though you might have to disable default form processing for the cancel button, depending on your form. HTH, Chris -- The Sanity Resort http://sanityresort.blogspot.com/ Am

Re: Non-Submit Button Not Getting Called from Form

2011-07-30 Thread Christian Huber
If you check the link sent by hariharansrc https://cwiki.apache.org/WICKET/multiple-submit-buttons.html you see an example with two submit buttons. The difference to your example, as far as i can see, is that your second button has not the submit type. To my understanding a button that is not

Re: can we do standalone projects in wicket

2011-07-30 Thread Christian Huber
What do you mean by standalone? Do you mean a framework for desktop applications? If so, then Swing or Eclipse RCP might be what you are looking for. -- The Sanity Resort http://sanityresort.blogspot.com/ Am 30.07.2011 16:46, schrieb hariharansrc: I actually don't understand what standalone

Re: Skip validation on nested form's form level validators

2011-07-11 Thread Christian Huber
Hi, well i _could_ decouple the two forms but that would kinda break my usecase and also the layout due to the changed component hierarchy. Removing and readding the validators does not strike me as a good idea though, that would mean that the outer form would have knowledge about the

Skip validation on nested form's form level validators

2011-07-10 Thread Christian Huber
Hi all, I have two forms nested within each other (wicket 1.4.17). The inner form adds data to the model of the outer form via ajax when it's button is pressed while the outer form saves the data to the database when the outer form's submit button is pressed. Both forms have validators

Re: Autocomplete - get model object

2011-07-06 Thread Christian Huber
Not sure if am understanding your problem correctly but how about this: The main problem is that those objects do not have ids associated with them because your service just does not use ids for the objects. But as far as i understood you have the chance to store the objects you need

Custom Validator Code

2011-07-05 Thread Christian Huber
Hi all, just in case this is of interest for anyone, I posted some code for custom validators that I consider useful for web applications here: http://sanityresort.blogspot.com/2011/07/some-of-my-custom-validatiors-for.html Feel free to let me know of any improvements or suggestions you have

Re: Behaviors beforeRender broken

2011-07-01 Thread Christian Huber
component in wicket terms s not correct. Any pointers would be greatly appreciated. Cheers, Chris Am 30.06.2011 22:20, schrieb Christian Huber: I just created a quick start with 1.4.17 where I added my behavior to the single label created in the template page. This time in addition

Behaviors beforeRender broken

2011-06-30 Thread Christian Huber
Hi all, I wanted to use a Behavior to customize the components in my application (Wicket 1.4.2) by modifying some properties in the behaviors beforeRender method. But I had to find that this method is never called, neither is afterRender. The other methods of the behavior are invoked but

Re: Behaviors beforeRender broken

2011-06-30 Thread Christian Huber
I tried adding a dummy implementation of that interface that logs every method call to custom subclass of link. While the links get rendered regularly the only methods that get invoked are isTemporary, bind, isEnabled and detach. All other methods are never called, am I missing something here?

Re: Behaviors beforeRender broken

2011-06-30 Thread Christian Huber
I just created a quick start with 1.4.17 where I added my behavior to the single label created in the template page. This time in addition to the methods mentioned below also getStatelessHint gets called but still beforeRender etc are not called. The label is still fully rendered. As Martin