Maybe SubmitLink is your solution,

usage as an anonymous class could look like this:

                add(new SubmitLink("lkjsdf", form) {
                        public void onSubmit() {
                               //Do what you need to do here.
                        }
                });

that way the browser will submit the form and send al the date in the input
fields.


Martin


Mattijs Hoitink wrote:
> 
> hi,
> 
> i'm just starting to use wicket and i have a question regarding updating 
> a model when a link is pressed. I will explain my situation.
> 
> I have a normal form, with a model attached to it and a button to submit 
> it. There is also a link in the form who's only purpose is to enable or 
> disable a field.
> The problem is, when i  press the link to disable the field, all my data 
> from the other fields is lost. It seems like wicket is loading a new 
> form when i presse the link, because all the old data from the model is 
> presented.
> 
> My question is: is it normal wicket loads the page again when a link is 
> pressed? and if so, is there a way to update my model first?
> 
> --
> Mattijs Hoitink
> Func. Internet Integration
> W http://www.func.nl
> T +31 20 4230000
> F +31 20 4223500
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Model-update-with-Link-tf4607178.html#a13155954
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to