[Wicket-user] Request attributes

2007-05-28 Thread Matthieu Casanova
Hi, I need some request attributes in my page. Those attributes aren't for session but only for the current request. To do that I made my own WebRequest that extends ServletWebRequest and changed the protected WebRequest newWebRequest(HttpServletRequest servletRequest) of my application to use

Re: [Wicket-user] integrating wicket and cocoon

2007-05-28 Thread Erik van Oosten
Hi Luca, Wicket uses the locale for finding resources (including the templates). You could do without but I am afraid it goes too far to let Wicket do something about Cocoon's incomplete HttpServletRequest implementation. So these are the options I see: 1. Make Cocoon behave itself by

Re: [Wicket-user] integrating wicket and cocoon

2007-05-28 Thread Martijn Dashorst
Fortunately, there are a couple of cocoon members hiding here (Sylvain, Jean-Baptiste, Upayavira) so there is a faint possibility that this can be addressed. In the mean time, I think you could override getLocale in your custom session, at least that was possible. Martijn On 5/28/07, Erik van

[Wicket-user] Binding pojo to (read only) page

2007-05-28 Thread Kees de Kooter
I come from a Spring MVC background. Spring MVC provides the spring:bind tag which basically allows to throw a pojo at the page and bind its properties. Is something similar possible with Wicket, without having to explicitly bind every property in the page class? -- Cheers, Kees de Kooter

Re: [Wicket-user] integrating wicket and cocoon

2007-05-28 Thread Johan Compagner
that will not work because the locale isn't get through the Session.getLocale() at that time. it is set in the session for the first time in 1.3 its in the constructor: protected Session(Application application, Request request) { this.locale = request.getLocale(); but i guess in

Re: [Wicket-user] Binding pojo to (read only) page

2007-05-28 Thread Korbinian Bachl
what you want is an CompoundPropertyModel: http://cwiki.apache.org/WICKET/working-with-wicket-models.html -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Kees de Kooter Gesendet: Montag, 28. Mai 2007 13:15 An:

Re: [Wicket-user] Binding pojo to (read only) page

2007-05-28 Thread Kees de Kooter
I have read about this. Unfortunately all the examples I found are with forms. I just want to display pojo values on a read only page. In the examples every property is still coded in the page class (e.g. in the page you refer to personForm.add(personModel.bind(new RequiredTextField(city),

Re: [Wicket-user] Binding pojo to (read only) page

2007-05-28 Thread Korbinian Bachl
well, if you just want to display, then you could use PropertyListView for a List containing your model-objects: http://cwiki.apache.org/WICKET/listview-and-other-repeaters.html this is also based on CompoundPropertyModel you even can just have a Label(foo) getting the getFoo() from a model

[Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread Korbinian Bachl
Hello, ive come to a problem I dont know how to solve. I use a BasePage in wich i have 2 RepeatingViews in wich i then put components (dynamic way at runtime - i dont know what component will be in) div wicket:id=header wicket:header container /div div wicket:id=content

Re: [Wicket-user] Best way to create large groups of similar tags

2007-05-28 Thread Thomas Singer
Thanks, Alexey and Kent, for your feed-back. Unfortunately, I still have do add a lot of components to the Page instance, for each line one. Tom Kent Tong wrote: Thomas Singer wicket at regnis.de writes: Generally, I want to keep the text (including the links to other pages in it) in the

[Wicket-user] Problem with AjaxLink and images in snapshot from this morning (1.3.0-incubating-SNAPSHOT)

2007-05-28 Thread Mats Norén
I've got a small snag with images inside an ajaxlink: My template looks like this: a wicket:id=previous class=marginRight href=# title=Bakaring;timg alt= class=middle src=img/button_goBack.gif/a The generated output when the page loads for the first time: a href=# title=Bakaring;t

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread James McLaughlin
Haven't done this, but I think you would need to override renderChild to get access to the component and setRenderBodyOnly. best, jim On 5/28/07, Korbinian Bachl [EMAIL PROTECTED] wrote: Hello, ive come to a problem I dont know how to solve. I use a BasePage in wich i have 2 RepeatingViews

Re: [Wicket-user] FileUploadField clear after failed validation. Still a bug?

2007-05-28 Thread manuel barzi
make a jira issue for this (if not already there) on the apache side (wicket sourceforge bug list got a bit lost) http://issues.apache.org/jira/browse/WICKET Ok, here it is ;) https://issues.apache.org/jira/browse/WICKET-596 If you supply patches it'll be fixed more quickly in

Re: [Wicket-user] Best way to create large groups of similar tags

2007-05-28 Thread Herman Bovens
Hm, can't you iterate over your collection of features and add the corresponding component in each iteration? Something like that? Thomas Singer-3 wrote: Thanks, Alexey and Kent, for your feed-back. Unfortunately, I still have do add a lot of components to the Page instance, for each

Re: [Wicket-user] Best way to create large groups of similar tags

2007-05-28 Thread Thomas Singer
Well, I guess I could use a Fragment (if it would work inside a Border) inside a RepeatingView, but then I would need to have all feature texts in the Java code, which is not nice but would work. Tom Herman Bovens wrote: Hm, can't you iterate over your collection of features and add the

[Wicket-user] Bookmarkable links with empty href

2007-05-28 Thread Alexey Maksimov
Hi, how to make a bookmarkable link in wicket to render as a href=# .../a ? I actually want to put a specific javascript in onclick(), that should work without reloading a page. Thanks in advance, Alexey. - This SF.net

Re: [Wicket-user] Best way to create large groups of similar tags

2007-05-28 Thread Martijn Dashorst
How do you determine if a feature is available or not? How do you know which feature you are currently processing? Are the features coming from a database/cms backend? If so, then why isn't the description available? Is that something you plan on adding in the future? Why does the page need to

Re: [Wicket-user] Binding pojo to (read only) page

2007-05-28 Thread Eelco Hillenius
You'd have to write a panel that iterates over the properties of an object using introspection. It's not difficult to write, but there is no standard component for this as of yet. Such a panel would contain a list view with a model that extracts the properties of an object and returns them as a

Re: [Wicket-user] I got this : Expected close tag for ...

2007-05-28 Thread Matthieu Casanova
2007/5/27, Kent Tong [EMAIL PROTECTED]: Matthieu Casanova chocolat.mou at gmail.com writes: html body span wicket:id=list label wicket:id=keykey/label span wicket:id=list2 label wicket:id=valueValue/label /span /span /body /html If you use a fragment inside

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread Eelco Hillenius
What about using: wicket:container wicket:id=header Eelco On 5/28/07, Korbinian Bachl [EMAIL PROTECTED] wrote: Hello, ive come to a problem I dont know how to solve. I use a BasePage in wich i have 2 RepeatingViews in wich i then put components (dynamic way at runtime - i dont know what

Re: [Wicket-user] Request attributes

2007-05-28 Thread Eelco Hillenius
What you do should work, or you could just get the request object from the Wicket request and cast it down to HttpServletRequest. Why do you need to set request attributes? Are you integrating with another technology, like JSPs? Eelco On 5/28/07, Matthieu Casanova [EMAIL PROTECTED] wrote: Hi,

Re: [Wicket-user] Request attributes

2007-05-28 Thread Matthieu Casanova
Hi, no, I'm not integrating with another technology. My problem is that for each request, I get some informations from a server, and I need those informations in several components to build my page. Those informations cannot be stored in session because they change at every request, and it is

[Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Thomas Singer
What's the best way for a transparent login? Example: When the user opens a mounted page and he is not logged in, a login page will be shown and after a successful login redirected to the originally requested page. Tom -

Re: [Wicket-user] Request attributes

2007-05-28 Thread Martijn Dashorst
If you can use PageParameters it would be neat (provide your Page's constructor with it). Otherwise, you'll have to use Eelco's method and query the request attributes. Martijn On 5/28/07, Matthieu Casanova [EMAIL PROTECTED] wrote: Hi, no, I'm not integrating with another technology. My problem

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Luca Marrocco
I'm not sure that exist a better way to do anything in software but a better way for specific problem and people. For me, in a spring wicket web application, the better way to implement trasparent login aka autentication and autorization concern is using acegi framework. Luca 2007/5/28, Thomas

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Martijn Dashorst
The typical Wicket Way (tm) of doing this is using the RestartResponseAtInterceptPageException [1] The wicket-auth-roles project and the new wicket-security projects hosted at WicketStuff also use it to guard authorized pages. Using a framework as Acegi limits you to URL based

Re: [Wicket-user] Request attributes

2007-05-28 Thread Matthieu Casanova
I don't think I can use PageParameters, my datas do not come from the client but from a server (the web server is connected to a server that provides it's data). Matthieu 2007/5/28, Martijn Dashorst [EMAIL PROTECTED]: If you can use PageParameters it would be neat (provide your Page's

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Thomas Singer
Should I store page parameters in the session myself before throwing the RestartResponseAtInterceptPageException in the page's constructor? How do I know to what page I should redirect after logging in? Tom Martijn Dashorst wrote: The typical Wicket Way (tm) of doing this is using the

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Thomas Singer
Never mind. RestartResponseAtInterceptPageException-handling is more lightweight than I assumed. Of course the other processing is completely up to me. Tom Thomas Singer wrote: Should I store page parameters in the session myself before throwing the RestartResponseAtInterceptPageException

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Thomas Singer
Never mind. RestartResponseAtInterceptPageException-handling is more lightweight than I assumed. Of course the other processing is completely up to me. Tom Thomas Singer wrote: Should I store page parameters in the session myself before throwing the RestartResponseAtInterceptPageException in

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread Korbinian Bachl
Hi Eelco, tried it, but this seems to go more buggy than before: if I use wicket:container wicket:id=header he complains about no end-tag, if i do wicket:container wicket:id=header / he renders, but puts out: panelcontent /wicket:container (yes , he doesnt print out the

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread Korbinian Bachl
Jim, thanks for your post - unfortunately i dont understand what you mean exactly: where should I overrrode renderChild and put what for? - the trouble for me is the base-tag of the RepeatingView, not the outputs of any of its childs... -Ursprüngliche Nachricht- Von: [EMAIL

Re: [Wicket-user] integrating wicket and cocoon

2007-05-28 Thread Jean-Baptiste Quenot
* Luca Marrocco: Our application is essentially based over cocoon (2.1.9) using a custom framework (around cform and flowscript, you anyone know was it) for controller development and client side interface. During this day we have interested to substitute cform (that is

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread James McLaughlin
Hi Korbinian, Well, the fundamental idea of ListView / RepeatingView is that the component has no markup of its own. The markup is given to the children. As such, setRenderBodyOnly on a RepeatingView does nothing. ListView provides populateItem, so you call setRenderBodyOnly on the item there.

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread Korbinian Bachl
Hi Jim, so if I understnad right then you mean the protected final void onRender(final MarkupStream markupStream) { final int markupStart = markupStream.getCurrentIndex(); Iterator it = renderIterator(); if (it.hasNext())

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Thomas Singer
Hm, by default, I'm getting an error that my page is not serializable. But when I set application.getDebugSettings().setSerializeSessionAttributes(false); it works without problems. Could this become a problem when my page still is not serializable? Tom Thomas Singer wrote: Never mind.

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread James McLaughlin
Not there, no. I mean, it is final, so it wouldn't work anyway. Just renderChild. Or even more direct, for each child you add to repeatingview, just call setRenderBodyOnly. Then you will see what I mean. Overriding renderChild was only meant to save you some code :). On 5/28/07, Korbinian Bachl

Re: [Wicket-user] RepeatingView/ Container behaviour

2007-05-28 Thread Korbinian Bachl
Ahh! - great! Thanks very much, it now works as expected! I mean, it is final, so it wouldn't work anyway. we both now you can hack around things like that ;) Overriding renderChild was only meant to save you some code :) as i already did a void addToHeader(Component c) it was only 1

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Maurice Marrink
On account of the serialization, yes this will become a problem for your backbutton support. wicket tries to serialize every page to disk and later retrieve it when a user used the browsers backbutton and then performs an action where it is necessary to go back to the server. On account of the

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Maurice Marrink
P.S you can read more here http://wicketstuff.org/confluence/display/STUFFWIKI/Wicket-Security Maurice On 5/28/07, Maurice Marrink [EMAIL PROTECTED] wrote: On account of the serialization, yes this will become a problem for your backbutton support. wicket tries to serialize every page to disk

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Thomas Singer
On account of the transparent login, like Martijn said if you use a framework for your security it is already handled automagically for you. Now i am a bit biased on the new wicket-security framework since i wrote it :), but you should really check it out sometime. To be exact, we don't need

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Maurice Marrink
Regarding the backbutton, When you press the backbutton on you're browser, it is the browser who gets the previous page from cache, the server is never notified of this. So regarding wicket, no there is not much you can do on that end. But you might be able with the help of some javascript to

[Wicket-user] Want to add a component to every AjaxRequestTarget

2007-05-28 Thread Jonathan Locke
Is there a way to hook every AJAX request and add a component (that's on every page) to the request target? It seems like there might be because of the way request targets work, but I don't have any idea what the details of that might look like... -- View this message in context:

Re: [Wicket-user] Serializable (Was: Bookmarkable pages and transparent login)

2007-05-28 Thread Thomas Singer
On account of the serialization, yes this will become a problem for your backbutton support. wicket tries to serialize every page to disk and later retrieve it when a user used the browsers backbutton and then performs an action where it is necessary to go back to the server. Hmm, looks

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Eelco Hillenius
On account of the serialization, yes this will become a problem for your backbutton support. wicket tries to serialize every page to disk and later retrieve it when a user used the browsers backbutton and then performs an action where it is necessary to go back to the server. One note here

Re: [Wicket-user] Bookmarkable pages and transparent login

2007-05-28 Thread Eelco Hillenius
Regarding the back-button: it would be the best if the intermediate license agreement page would not occur when pressing the back-button, but instead the previous page (if any). Is something like that possible? What you need to achieve is that the URL stays stable. One way to achieve this is

Re: [Wicket-user] Serializable (Was: Bookmarkable pages and transparent login)

2007-05-28 Thread Eelco Hillenius
Is there some possibility to avoid the serialization? Yes, at least theoretically there is by messing with page maps. It's actually really easy in Wicket 1.3 where you can provide a custom session store that never relies on serialization. We have a couple of classes which have final fields

Re: [Wicket-user] Request attributes

2007-05-28 Thread Jean-Baptiste Quenot
* Matthieu Casanova: I don't think I can use PageParameters, my datas do not come from the client but from a server (the web server is connected to a server that provides it's data). You should consider PageParameters as just a concept in the API. To produce your own PageParameters from the

Re: [Wicket-user] wicket-1.3b1 examples

2007-05-28 Thread Reinout van Schouwen
Hello Eelco, Op vrijdag 25-05-2007 om 23:12 uur [tijdzone +0200], schreef Eelco Hillenius: in your application's init method my application doesn't exist yet, I'm just trying to build the examples. (or update to the latest Wicket snapshot)? If the problem stays, it should give you a

Re: [Wicket-user] wicket-1.3b1 examples

2007-05-28 Thread Eelco Hillenius
Today I pulled wicket-1.3-SNAPSHOT from svn and built it. When I disable the tests, the build is OK, but with tests enabled many other errors showed up than the one I asked about in my original post. (I don't think I have to post them here, as anyone should be able to reproduce this?!) Should

Re: [Wicket-user] TreeTable with nodes that are not links + rows with alternate background colours

2007-05-28 Thread jweekend
I have moved up to 1.2.6 of wicket extensions (to match my wicket version), and I am not seeing warnings about gifs being requested now if I hover fast over nodes. Does anyone have any ideas regarding the post below ie 1 - how to make a TreeTable with nodes not) as links, and, 2 - to display

Re: [Wicket-user] nested wicket:ids

2007-05-28 Thread jweekend
Thanks Herman. Yes, naturally, I started out with that. I think it's to do with hierarchies and scopes. I will try out your advice about my invisible span tag in _this_ post. Strangely, I found that there was no problem if I added the text field (waitedForId in my example below) to the radio

Re: [Wicket-user] nested wicket:ids

2007-05-28 Thread howzat
Thanks Herman. Yes, naturally, I started out with that. I think it's to do with hierarchies and scopes. I will try out your advice about my invisible span tag in _this_ post. Strangely, I found that there was no problem if I added the text field (waitedForId in my example below) to the radio

Re: [Wicket-user] TreeTable with nodes that are not links + rows with alternate background colours

2007-05-28 Thread howzat
Has anybody got any further thoughts on this? howzat wrote: wicket: 1.2.6 wicket-extensions: 1.2.6 A couple of questions re TreeTable Is it possible to configure a TreeTable so its nodes are not links? So far, I have only found/tried tree.setLinkType(null) without achieving

[Wicket-user] Wizard question

2007-05-28 Thread Herman Bovens
Suppose I have a WizardStep that depends on the information that the user entered/selected in a previous step. I will need to build the components when this WizardStep is activated, which means the previous step has been completed. This means I can't do it in the constructor because it is

Re: [Wicket-user] Wizard question

2007-05-28 Thread howzat
Take a look at: http://www.wicket-wiki.org.uk/wiki/index.php/Building_wizard_functionality There is a very simple and and helpful example on the wicket extensions examples page too (which seems to be unavailable just now). Herman Bovens wrote: Suppose I have a WizardStep that depends on the

Re: [Wicket-user] Wizard question

2007-05-28 Thread Eelco Hillenius
Look at NewUserWizard from org.apache.wicket.examples.wizard. All steps share the same model, which is the user instance that is a member of the NewUserWizard itself. You can work much in the same fashion. Eelco On 5/28/07, Herman Bovens [EMAIL PROTECTED] wrote: Suppose I have a WizardStep

Re: [Wicket-user] Want to add a component to every AjaxRequestTarget

2007-05-28 Thread Eelco Hillenius
One way is to create a custom request cycle processor (extend WebRequestCycleProcessor) and e.g. override processEvents and check what the current request target is (do something when it is an AjaxRequestTarget). Eelco On 5/28/07, Jonathan Locke [EMAIL PROTECTED] wrote: Is there a way to hook

Re: [Wicket-user] Problem with AjaxLink and images in snapshot from this morning (1.3.0-incubating-SNAPSHOT)

2007-05-28 Thread Eelco Hillenius
Can you update and see whether the problem is still there? Eelco On 5/28/07, Mats Norén [EMAIL PROTECTED] wrote: I've got a small snag with images inside an ajaxlink: My template looks like this: a wicket:id=previous class=marginRight href=# title=Bakaring;timg alt= class=middle

Re: [Wicket-user] Want to add a component to every AjaxRequestTarget

2007-05-28 Thread Jonathan Locke
ah yeah, that's what i was vaguely thinking was the way but not quite remembering. thanks! Eelco Hillenius wrote: One way is to create a custom request cycle processor (extend WebRequestCycleProcessor) and e.g. override processEvents and check what the current request target is (do

[Wicket-user] PasswordTextField reset bug

2007-05-28 Thread Ingram Chen
All, In wicket 1.2.6, I try to do passwordTextField.setResetPassword(false). But I found that password field always got reset if model object is blank. It seems that password field never use preserved rawInput to render: protected final void onComponentTag(final ComponentTag tag) {