Reusable DateColumn component

2008-10-05 Thread Edgar Merino
Hello, a few days ago someone requested some advice on how to format the 
date within an IColumn, I suggested DateColumn that depended on his 
code, but I've been having this necessity in several ocassions too, so 
I've come up with a true reusable DateColumn component that inherits 
from PropertyColumn, so using it is as simple as:


(DateColumn class shown below)

ListIColumn cols = new ArrayListIColumn();
cols.add(new DateColumn(new Model(header title), propertyExpression));

No extra code needed, regards.
Edgar Merino


import java.util.Date;
import java.text.DateFormat;
import java.text.SimpleDateFormat;

import org.apache.wicket.model.IModel;
import org.apache.wicket.model.Model;
import org.apache.wicket.util.lang.PropertyResolver;
import 
org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;


/**
* PropertyColumn descendent, used to apply a format to a Date field to 
be displayed

* by a Label in a DataTable
*
* @author Edgar Merino
*/
public class DateColumn extends PropertyColumn {   
   public  static final String DEFAULT_DATE_PATTERN = dd MMM  '@' 
hh:mm a;
   private String datePattern;   
  
   public DateColumn(IModel displayModel, String propertyExpression) {

   this(displayModel, DEFAULT_DATE_PATTERN, propertyExpression);
   }   
  
   public DateColumn(IModel displayModel, String datePattern, String 
propertyExpression) {

   this(displayModel, null, datePattern, propertyExpression);
   }
  
   public DateColumn(IModel displayModel, String sortProperty, String 
datePattern, String propertyExpression) {
   super(displayModel, propertyExpression);   
   this.datePattern = datePattern;

   }

   @Override
   protected IModel createLabelModel(IModel itemModel) {
   Date date = (Date) 
PropertyResolver.getValue(getPropertyExpression(), itemModel.getObject());
   SimpleDateFormat df = (SimpleDateFormat) 
DateFormat.getDateInstance();

   df.applyPattern(datePattern);
  
   return new Model(df.format(date));

   }
}


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



ModalWindow and IAjaxIndicatorAware

2008-10-05 Thread Eyal Golan
Hi,
I have a modal window that updates a page (the page it was initiated from).
It updates a URL string in an inline frame src:
IModel iframeModel = new AbstractReadOnlyModel() {
private static final long serialVersionUID = 1L;

@Override
public Object getObject() {
return reportSrcUrl; // this is updated when the modal
window OK button is pressed
}

};
InlineFrame iframe =
new InlineFrame(iframe, getPage().getPageMap(),
ReportPage.class);
iframe.add(new AttributeModifier(src, true, iframeModel));
Naturally I add the inline frame to the target when the modal window is
closed.

The issue is this:
The operation of changing the src might take a while and I want to show an
indication.
I have set the page to be IAjaxIndicatorAware and used
WicketAjaxIndicatorAppender (just like the indicating ajax button).
Naturally it didn't work :)

Has anyone did something similar?

Thanks

-- 
Eyal Golan
[EMAIL PROTECTED]

Visit: http://jvdrums.sourceforge.net/
LinkedIn: http://www.linkedin.com/in/egolan74

P  Save a tree. Please don't print this e-mail unless it's really necessary


Re: setOutputMarkupId and Ajax

2008-10-05 Thread Mathias P.W Nilsson

No, I understand. An eclipse plugin could solve a lot of this issues. An
Wicket view that could warn, etc for all things that could go wrong.

I understand now why the programmer needs to set the output and not the
framework
-- 
View this message in context: 
http://www.nabble.com/setOutputMarkupId-and-Ajax-tp19802839p19822392.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Form GET doesn't call onSubmit method

2008-10-05 Thread eyalbenamram

Hi
Is there a way to override this bug? the problem is I need a solution for
the problem NOW 
and I cannot wait for the next version of wicket to come out...

Thanks, Eyal.


Erik van Oosten wrote:
 
 Hi Eyal,
 
 Let me translate Igor's reponse (which I agree is somewhat short for the 
 uninitiated ;)  )
 
 Quickstart is the optimum way to start with Wicket. For more info see 
 http://wicket.apache.org/quickstart.html.
 
 A quickstart is an as small as possible Wicket application that 
 demonstrates a bug and was created with Quickstart.
 
 Igor's question also indicates he thinks there is a bug. You can file 
 the bug by creating an issue in Wicket's bug tracking system at: 
 https://issues.apache.org/jira/browse/WICKET. The quickstart should be 
 attached to the created issue.
 
 Regards,
 Erik.
 
 
 eyalbenamram wrote:
 Hi
 How? what is a quickstart? 
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:
   
 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:
 
 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called and I
 am routed to the home page instead of the location I specified. Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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



 

   
 
 
 -- 
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823854.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Session ID and Sesson destroy

2008-10-05 Thread Stefan Lindner
I need to perform some actions on sesson destroy or after session is
destroyed. In Application I can override ths sessionDestroyed method.
This method hast he session id as it's parameter. So it should be
possible to address a certain Sesson. But how can I obtain the session's
id on creation? When I override the Application's newSession and create
an instance of MyOwnSesson, I have no session id at this moment. A call
to 
getSessionStore().getSessionId(request, false) leads to null becaus the
sesson is not in the session store at this moment. But is it possible to
detect the session id that the session will have after insertion into
the sessoinStore?

Stefan

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



Re: Wrapped FeedbackPanel and AjaxRequestTarget

2008-10-05 Thread Edgar Merino
Never mind, I guess this can be solved by calling the actual Parent that 
holds the FeedbackPanel:


Component parent = null;
do {
   parent = feedbackPanel.getParent();
} while(parent.getParent() != null);

Regards,
Edgar Merino


Edgar Merino escribió:

Hello once again,

   I've been coding some Panels that might (or might not) use a 
FeedbackPanel to inform about their states, these panels are Ajax 
enabled. Since the feedbackPanel does not reside on the panel itself 
(it is added to the panels parent component), I've decided to come out 
with a wrapper panel that should support this out of the box (shown 
below), the problem is that after calling infoFeedback(some msg, 
target) I don't see the message displayed in the Parent component (a 
WebPage). I thought calling FeedbackPanel#getParent()#info(String msg) 
will do the trick, but I guess I was wrong. I would really appreciate 
any help.


public abstract class FeedbackHolderPanel extends Panel {
   private FeedbackPanel feedbackPanel;
 public FeedbackHolderPanel(String id) {
   super(id);
   }
 public Panel addFeedbackPanel(FeedbackPanel feedbackPanel) 
{  this.feedbackPanel = feedbackPanel;

   feedbackPanel.setOutputMarkupId(true);
 return this;
   }
 protected void infoFeedback(String msg, AjaxRequestTarget target) {
   if (feedbackPanel != null) {
   feedbackPanel.getParent().info(msg);
   addToTarget(target);  }
   }
 .. {same goes for warn and error} ...
 protected FeedbackPanel getFeedbackPanel() {
   return feedbackPanel;
   }
 private void addToTarget(AjaxRequestTarget target) {
   if (target != null) {
   target.addComponent(feedbackPanel);
   }
   }
}

Thanks in advance
Edgar Merino




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



Re: Form GET doesn't call onSubmit method

2008-10-05 Thread eyalbenamram

Hi
Is there a way to override this bug? the problem is I need a solution for
the problem NOW 
and I cannot wait for the next version of wicket to come out...

Thanks, Eyal.


Erik van Oosten wrote:
 
 Hi Eyal,
 
 Let me translate Igor's reponse (which I agree is somewhat short for the 
 uninitiated ;)  )
 
 Quickstart is the optimum way to start with Wicket. For more info see 
 http://wicket.apache.org/quickstart.html.
 
 A quickstart is an as small as possible Wicket application that 
 demonstrates a bug and was created with Quickstart.
 
 Igor's question also indicates he thinks there is a bug. You can file 
 the bug by creating an issue in Wicket's bug tracking system at: 
 https://issues.apache.org/jira/browse/WICKET. The quickstart should be 
 attached to the created issue.
 
 Regards,
 Erik.
 
 
 eyalbenamram wrote:
 Hi
 How? what is a quickstart? 
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:
   
 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:
 
 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called and I
 am routed to the home page instead of the location I specified. Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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



 

   
 
 
 -- 
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823522.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



form GET calling onSubmit

2008-10-05 Thread eyalbenamram

Hi
There is a bug in wicket of a form that uses the GET method 
never calls the onSubmit method. 
I am now using wicket 1.4 m3, and the bug (already reported long time ago)
is still not fixed, though it is said it was fixed. here is my code:

Button backBtn = new Button(back_button, new
Model(getString(back)));

Form form = new Form(form) {
public void onSubmit() {
setResponsePage(prevPage);
}

protected String getMethod() {
   return get;
}
};
form.add(backBtn);

add(form);

What am I doing wrong???

thanks, Eyal.
-- 
View this message in context: 
http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19824816.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Client side validation behaviors - already started?

2008-10-05 Thread Jörn Zaefferer
First thing that I have to notice:
ClientAndServerExactLengthValidatingBehavior is an awful class name.
LengthValidation would be enough.

The other thing: I wouldn't use clientside validation when it
validates on submit only. It should validate non-empty fields on blur,
and fields already marked as invalid on keyup. Without that there
really isn't much of a point in using clientside validation at all.

I'll try to look at your actual code, though some examples would help a lot!

Jörn

On Sun, Oct 5, 2008 at 7:33 AM, Jeremy Thomerson
[EMAIL PROTECTED] wrote:
 Okay, I was able to commit what I had already started on.  This is only a
 few hours work, so it is nowhere near complete.  However, I have the basis
 for the framework, and a replica of all the StringValidator validation
 done.

 https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicketstuff-client-and-server-validation/

 Here are the basic features:

   - By simply replacing formcomponent.add(StringValidator.exactLength(4))
   with add(new ClientAndServerExactLengthValidatingBehavior(form, 4)), it will
   do the client side validation and add the server side IValidator for you.
   - It is internationalized because it uses all of the same resource keys /
   messages that the standard Wicket validators use.
   - It can insert feedback messages onto the page in a feedback panel or
   other WebMarkupContainer by calling feedbackpanel.add(new
   ClientAndServerValidatingFeedbackBehavior(form)) - this will make it use the
   same appearance that the normal feedback panel would generate.

 I'm sure there is quite a bit of stuff that can be cleaned up, especially in
 the JS code.  For instance, I'm using document.getElementById quite a bit,
 but I'm not sure if there are some browsers that may not support that.  I
 need to look because I can't remember.  Anyway, feedback is welcome!

 NOTE: I had started it within another project and was testing it there.  I
 have not had time to test it again after I moved it to its own project.
 Since all I did was move it, add the license info and rename the packages,
 it should still work, but you know how that goes.

 --
 Jeremy Thomerson
 http://www.wickettraining.com


 On Sat, Oct 4, 2008 at 9:39 AM, Jeremy Thomerson
 [EMAIL PROTECTED]wrote:

 Basically, where you would normally call:
 Formcomponent.add(IValidator),
 You could now add a behavior.  In my behavior, on bind I add the
 server-side equivalent validator.  Then in renderHead, I add some onLoad JS
 that adds the component to a JS array of components to be validated on form
 submit.

 Let me get a little more of the basic started, and then I would REALLY
 welcome the help!  Maybe tomorrow night or Monday I can get a wicketstuff
 project started for it...

 The help will be great - my JS fu is rusty!

 Jeremy Thomerson
 http://www.wickettraining.com
 -- sent from a wireless device


 -Original Message-
 From:  Jörn Zaefferer  =F6rn_Zaefferer _ [EMAIL PROTECTED]
 Sent: Saturday, October 04, 2008 5:50 AM
 To: users@wicket.apache.org
 Subject: Re: Client side validation behaviors - already started?

 What approach for client-side validation are you looking for? I may be
 able to help with that.

 Jörn

 On Fri, Oct 3, 2008 at 5:50 AM, Jeremy Thomerson
 [EMAIL PROTECTED] wrote:
  I've been thinking of trying to create some behaviors that combine the
  standard server-side validation with client-side validation.  I just
 wanted
  to check to see if anyone knew of something like this already started.  I
  don't want to duplicate work already done.
 
  Thanks,
 
  --
  Jeremy Thomerson
  http://www.wickettraining.com
 




Re: Form GET doesn't call onSubmit method

2008-10-05 Thread Igor Vaynberg
first you have to figure out why its not getting called

-igor

On Sun, Oct 5, 2008 at 4:10 AM, eyalbenamram [EMAIL PROTECTED] wrote:

 Hi
 Is there a way to override this bug? the problem is I need a solution for
 the problem NOW
 and I cannot wait for the next version of wicket to come out...

 Thanks, Eyal.


 Erik van Oosten wrote:

 Hi Eyal,

 Let me translate Igor's reponse (which I agree is somewhat short for the
 uninitiated ;)  )

 Quickstart is the optimum way to start with Wicket. For more info see
 http://wicket.apache.org/quickstart.html.

 A quickstart is an as small as possible Wicket application that
 demonstrates a bug and was created with Quickstart.

 Igor's question also indicates he thinks there is a bug. You can file
 the bug by creating an issue in Wicket's bug tracking system at:
 https://issues.apache.org/jira/browse/WICKET. The quickstart should be
 attached to the created issue.

 Regards,
 Erik.


 eyalbenamram wrote:
 Hi
 How? what is a quickstart?
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:

 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called and I
 am routed to the home page instead of the location I specified. Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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








 --
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/


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




 --
 View this message in context: 
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823522.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: Session ID and Sesson destroy

2008-10-05 Thread Igor Vaynberg
as per servlet spec, when you get session destroyed notification you
have the session id, but you can no longer access session...

-igor

On Sun, Oct 5, 2008 at 1:47 AM, Stefan Lindner [EMAIL PROTECTED] wrote:
 I need to perform some actions on sesson destroy or after session is
 destroyed. In Application I can override ths sessionDestroyed method.
 This method hast he session id as it's parameter. So it should be
 possible to address a certain Sesson. But how can I obtain the session's
 id on creation? When I override the Application's newSession and create
 an instance of MyOwnSesson, I have no session id at this moment. A call
 to
 getSessionStore().getSessionId(request, false) leads to null becaus the
 sesson is not in the session store at this moment. But is it possible to
 detect the session id that the session will have after insertion into
 the sessoinStore?

 Stefan

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



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



Re: form GET calling onSubmit

2008-10-05 Thread Igor Vaynberg
where is the bug report?

-igor

On Sun, Oct 5, 2008 at 6:56 AM, eyalbenamram [EMAIL PROTECTED] wrote:

 Hi
 There is a bug in wicket of a form that uses the GET method
 never calls the onSubmit method.
 I am now using wicket 1.4 m3, and the bug (already reported long time ago)
 is still not fixed, though it is said it was fixed. here is my code:

Button backBtn = new Button(back_button, new
 Model(getString(back)));

Form form = new Form(form) {
public void onSubmit() {
setResponsePage(prevPage);
}

protected String getMethod() {
   return get;
}
};
form.add(backBtn);

add(form);

 What am I doing wrong???

 thanks, Eyal.
 --
 View this message in context: 
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19824816.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: Form GET doesn't call onSubmit method

2008-10-05 Thread eyalbenamram

I have no idea why.. I think it is a bug.. when using
POST it works just fine.
So is there a way to use GET and call onSubmit in another way?



igor.vaynberg wrote:
 
 first you have to figure out why its not getting called
 
 -igor
 
 On Sun, Oct 5, 2008 at 4:10 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 Is there a way to override this bug? the problem is I need a solution for
 the problem NOW
 and I cannot wait for the next version of wicket to come out...

 Thanks, Eyal.


 Erik van Oosten wrote:

 Hi Eyal,

 Let me translate Igor's reponse (which I agree is somewhat short for the
 uninitiated ;)  )

 Quickstart is the optimum way to start with Wicket. For more info see
 http://wicket.apache.org/quickstart.html.

 A quickstart is an as small as possible Wicket application that
 demonstrates a bug and was created with Quickstart.

 Igor's question also indicates he thinks there is a bug. You can file
 the bug by creating an issue in Wicket's bug tracking system at:
 https://issues.apache.org/jira/browse/WICKET. The quickstart should be
 attached to the created issue.

 Regards,
 Erik.


 eyalbenamram wrote:
 Hi
 How? what is a quickstart?
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:

 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called and I
 am routed to the home page instead of the location I specified. Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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








 --
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/


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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823522.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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

-- 
View this message in context: 
http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19825976.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Form GET doesn't call onSubmit method

2008-10-05 Thread Igor Vaynberg
just tried the code you pasted in the other email and it works fine
for me. this is why i asked for a quickstart...for now i cant
reproduce your problem.

-igor

On Sun, Oct 5, 2008 at 8:57 AM, eyalbenamram [EMAIL PROTECTED] wrote:

 I have no idea why.. I think it is a bug.. when using
 POST it works just fine.
 So is there a way to use GET and call onSubmit in another way?



 igor.vaynberg wrote:

 first you have to figure out why its not getting called

 -igor

 On Sun, Oct 5, 2008 at 4:10 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 Is there a way to override this bug? the problem is I need a solution for
 the problem NOW
 and I cannot wait for the next version of wicket to come out...

 Thanks, Eyal.


 Erik van Oosten wrote:

 Hi Eyal,

 Let me translate Igor's reponse (which I agree is somewhat short for the
 uninitiated ;)  )

 Quickstart is the optimum way to start with Wicket. For more info see
 http://wicket.apache.org/quickstart.html.

 A quickstart is an as small as possible Wicket application that
 demonstrates a bug and was created with Quickstart.

 Igor's question also indicates he thinks there is a bug. You can file
 the bug by creating an issue in Wicket's bug tracking system at:
 https://issues.apache.org/jira/browse/WICKET. The quickstart should be
 attached to the created issue.

 Regards,
 Erik.


 eyalbenamram wrote:
 Hi
 How? what is a quickstart?
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:

 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called and I
 am routed to the home page instead of the location I specified. Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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








 --
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/


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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823522.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context: 
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19825976.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: form GET calling onSubmit

2008-10-05 Thread eyalbenamram

JIRA:
https://issues.apache.org/jira/browse/WICKET-1580


igor.vaynberg wrote:
 
 where is the bug report?
 
 -igor
 
 On Sun, Oct 5, 2008 at 6:56 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 There is a bug in wicket of a form that uses the GET method
 never calls the onSubmit method.
 I am now using wicket 1.4 m3, and the bug (already reported long time
 ago)
 is still not fixed, though it is said it was fixed. here is my code:

Button backBtn = new Button(back_button, new
 Model(getString(back)));

Form form = new Form(form) {
public void onSubmit() {
setResponsePage(prevPage);
}

protected String getMethod() {
   return get;
}
};
form.add(backBtn);

add(form);

 What am I doing wrong???

 thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19824816.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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

-- 
View this message in context: 
http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19826029.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: AbstractPageStore memory implementation instead of disk

2008-10-05 Thread richardwilko

The wicket integration with terracotta uses an in-memory page map.

The code is here, but will soon be part of the terracotta wicket-tim.

http://www.nabble.com/file/p19826206/TerracottaPageStore.java
TerracottaPageStore.java 



Timo Rantalaiho wrote:
 
 On Fri, 03 Oct 2008, Igor Vaynberg wrote:
 do you have some statistics for us? or some profiler timing screenshots?
 
 While waiting for the reply from Ard... I remember hearing
 of a case where the pagemaps were stored to a directory that
 the virus scanner was monitoring, and the scanner hogged all
 cpu during load testing :) I suppose that this kind of 
 stuff happens more easily on Windows than on unices.
 
 Best wishes,
 Timo
 
 -- 
 Timo Rantalaiho   
 Reaktor Innovations OyURL: http://www.ri.fi/ 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 


-
http://www.richard-wilkinson.co.uk My blog:
http://www.richard-wilkinson.co.uk 
-- 
View this message in context: 
http://www.nabble.com/AbstractPageStore-memory-implementation-instead-of-disk-tp19797628p19826206.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Form GET doesn't call onSubmit method

2008-10-05 Thread eyalbenamram

I will try to reproduce it in a quickstart application..
If you won't hear from me again about this problem - it's probably because 
it worked. 
One last question: can you think of something I did that caused this problem
to occure?
My thougths are: if it works for quickstart app but not for me - what did I
do wrong?


igor.vaynberg wrote:
 
 just tried the code you pasted in the other email and it works fine
 for me. this is why i asked for a quickstart...for now i cant
 reproduce your problem.
 
 -igor
 
 On Sun, Oct 5, 2008 at 8:57 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 I have no idea why.. I think it is a bug.. when using
 POST it works just fine.
 So is there a way to use GET and call onSubmit in another way?



 igor.vaynberg wrote:

 first you have to figure out why its not getting called

 -igor

 On Sun, Oct 5, 2008 at 4:10 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 Is there a way to override this bug? the problem is I need a solution
 for
 the problem NOW
 and I cannot wait for the next version of wicket to come out...

 Thanks, Eyal.


 Erik van Oosten wrote:

 Hi Eyal,

 Let me translate Igor's reponse (which I agree is somewhat short for
 the
 uninitiated ;)  )

 Quickstart is the optimum way to start with Wicket. For more info
 see
 http://wicket.apache.org/quickstart.html.

 A quickstart is an as small as possible Wicket application that
 demonstrates a bug and was created with Quickstart.

 Igor's question also indicates he thinks there is a bug. You can file
 the bug by creating an issue in Wicket's bug tracking system at:
 https://issues.apache.org/jira/browse/WICKET. The quickstart should be
 attached to the created issue.

 Regards,
 Erik.


 eyalbenamram wrote:
 Hi
 How? what is a quickstart?
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:

 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram
 [EMAIL PROTECTED]
 wrote:

 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called and
 I
 am routed to the home page instead of the location I specified. Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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








 --
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/


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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823522.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19825976.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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

-- 
View this message in context: 
http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19826276.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: form GET calling onSubmit

2008-10-05 Thread Igor Vaynberg
are you using a StatelessForm? because in your example you showed a regular form

-igor

On Sun, Oct 5, 2008 at 9:04 AM, eyalbenamram [EMAIL PROTECTED] wrote:

 JIRA:
 https://issues.apache.org/jira/browse/WICKET-1580


 igor.vaynberg wrote:

 where is the bug report?

 -igor

 On Sun, Oct 5, 2008 at 6:56 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 There is a bug in wicket of a form that uses the GET method
 never calls the onSubmit method.
 I am now using wicket 1.4 m3, and the bug (already reported long time
 ago)
 is still not fixed, though it is said it was fixed. here is my code:

Button backBtn = new Button(back_button, new
 Model(getString(back)));

Form form = new Form(form) {
public void onSubmit() {
setResponsePage(prevPage);
}

protected String getMethod() {
   return get;
}
};
form.add(backBtn);

add(form);

 What am I doing wrong???

 thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19824816.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context: 
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19826029.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: Form GET doesn't call onSubmit method

2008-10-05 Thread Igor Vaynberg
no idea if it works for post but not get...

-igor

On Sun, Oct 5, 2008 at 9:26 AM, eyalbenamram [EMAIL PROTECTED] wrote:

 I will try to reproduce it in a quickstart application..
 If you won't hear from me again about this problem - it's probably because
 it worked.
 One last question: can you think of something I did that caused this problem
 to occure?
 My thougths are: if it works for quickstart app but not for me - what did I
 do wrong?


 igor.vaynberg wrote:

 just tried the code you pasted in the other email and it works fine
 for me. this is why i asked for a quickstart...for now i cant
 reproduce your problem.

 -igor

 On Sun, Oct 5, 2008 at 8:57 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 I have no idea why.. I think it is a bug.. when using
 POST it works just fine.
 So is there a way to use GET and call onSubmit in another way?



 igor.vaynberg wrote:

 first you have to figure out why its not getting called

 -igor

 On Sun, Oct 5, 2008 at 4:10 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 Is there a way to override this bug? the problem is I need a solution
 for
 the problem NOW
 and I cannot wait for the next version of wicket to come out...

 Thanks, Eyal.


 Erik van Oosten wrote:

 Hi Eyal,

 Let me translate Igor's reponse (which I agree is somewhat short for
 the
 uninitiated ;)  )

 Quickstart is the optimum way to start with Wicket. For more info
 see
 http://wicket.apache.org/quickstart.html.

 A quickstart is an as small as possible Wicket application that
 demonstrates a bug and was created with Quickstart.

 Igor's question also indicates he thinks there is a bug. You can file
 the bug by creating an issue in Wicket's bug tracking system at:
 https://issues.apache.org/jira/browse/WICKET. The quickstart should be
 attached to the created issue.

 Regards,
 Erik.


 eyalbenamram wrote:
 Hi
 How? what is a quickstart?
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:

 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram
 [EMAIL PROTECTED]
 wrote:

 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called and
 I
 am routed to the home page instead of the location I specified. Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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








 --
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/


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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823522.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19825976.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context: 
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19826276.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



Re: form GET calling onSubmit

2008-10-05 Thread eyalbenamram

No, I am using a regular form. the example I brought was to show the JIRA
report.
There was a report regarding the regular form but I couldn't find it.

igor.vaynberg wrote:
 
 are you using a StatelessForm? because in your example you showed a
 regular form
 
 -igor
 
 On Sun, Oct 5, 2008 at 9:04 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 JIRA:
 https://issues.apache.org/jira/browse/WICKET-1580


 igor.vaynberg wrote:

 where is the bug report?

 -igor

 On Sun, Oct 5, 2008 at 6:56 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 There is a bug in wicket of a form that uses the GET method
 never calls the onSubmit method.
 I am now using wicket 1.4 m3, and the bug (already reported long time
 ago)
 is still not fixed, though it is said it was fixed. here is my code:

Button backBtn = new Button(back_button, new
 Model(getString(back)));

Form form = new Form(form) {
public void onSubmit() {
setResponsePage(prevPage);
}

protected String getMethod() {
   return get;
}
};
form.add(backBtn);

add(form);

 What am I doing wrong???

 thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19824816.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context:
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19826029.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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

-- 
View this message in context: 
http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19826373.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: Form GET doesn't call onSubmit method

2008-10-05 Thread eyalbenamram

OK..  thanks anyway


igor.vaynberg wrote:
 
 no idea if it works for post but not get...
 
 -igor
 
 On Sun, Oct 5, 2008 at 9:26 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 I will try to reproduce it in a quickstart application..
 If you won't hear from me again about this problem - it's probably
 because
 it worked.
 One last question: can you think of something I did that caused this
 problem
 to occure?
 My thougths are: if it works for quickstart app but not for me - what did
 I
 do wrong?


 igor.vaynberg wrote:

 just tried the code you pasted in the other email and it works fine
 for me. this is why i asked for a quickstart...for now i cant
 reproduce your problem.

 -igor

 On Sun, Oct 5, 2008 at 8:57 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 I have no idea why.. I think it is a bug.. when using
 POST it works just fine.
 So is there a way to use GET and call onSubmit in another way?



 igor.vaynberg wrote:

 first you have to figure out why its not getting called

 -igor

 On Sun, Oct 5, 2008 at 4:10 AM, eyalbenamram [EMAIL PROTECTED]
 wrote:

 Hi
 Is there a way to override this bug? the problem is I need a solution
 for
 the problem NOW
 and I cannot wait for the next version of wicket to come out...

 Thanks, Eyal.


 Erik van Oosten wrote:

 Hi Eyal,

 Let me translate Igor's reponse (which I agree is somewhat short for
 the
 uninitiated ;)  )

 Quickstart is the optimum way to start with Wicket. For more info
 see
 http://wicket.apache.org/quickstart.html.

 A quickstart is an as small as possible Wicket application that
 demonstrates a bug and was created with Quickstart.

 Igor's question also indicates he thinks there is a bug. You can
 file
 the bug by creating an issue in Wicket's bug tracking system at:
 https://issues.apache.org/jira/browse/WICKET. The quickstart should
 be
 attached to the created issue.

 Regards,
 Erik.


 eyalbenamram wrote:
 Hi
 How? what is a quickstart?
 I am using wicket 1.3.4  is it still not fixed there?



 igor.vaynberg wrote:

 create a quickstart and attach it to a jira issue

 -igor

 On Thu, Oct 2, 2008 at 7:09 AM, eyalbenamram
 [EMAIL PROTECTED]
 wrote:

 Hi,
 I have a form that overrides the method:

protected String getMethod() {

   return Form.METHOD_GET;
 }

 When the form is submitted, the onSubmit method is never called
 and
 I
 am routed to the home page instead of the location I specified.
 Any
 suggestions??

 Thanks, Eyal.
 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19780009.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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








 --
 Erik van Oosten
 http://www.day-to-day-stuff.blogspot.com/


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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19823522.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19825976.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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



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




 --
 View this message in context:
 http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19826276.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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

-- 
View this message in context: 
http://www.nabble.com/Form-GET-doesn%27t-call-onSubmit-method-tp19780009p19826384.html
Sent from the Wicket - User mailing 

Re: form GET calling onSubmit

2008-10-05 Thread Jeremy Thomerson
Eyal,
  The code you supplied seems to work for me, and Igor said in the other
thread that it worked for him as well.  Here is the code for another example
I did to test it.  If you can produce some code that doesn't work, everyone
will be able to help more.  In the meantime, if you try the code you posted
again, or use this code, maybe it will work for you.

  By the way - is it possible that you had setRequired(true) or some
validator on one of your inputs that was producing a validation error?  This
would stop the form from ever getting to the onSubmit, and you might not
know it if you didn't have a feedback panel to show the validation error.

-- 
Jeremy Thomerson
http://www.wickettraining.com


Some code that definitely works:

public class Mockup extends WebPage {

private String message = TEST;

public Mockup(){
FormVoid form = new FormVoid(form) {
private static final long serialVersionUID = 1L;

@Override
protected void onSubmit() {
super.onSubmit();
System.out.println(Message:  + message);
setResponsePage(HomePage.class);
}

@Override
protected String getMethod() {
return Form.METHOD_GET;
}

};
form.add(new TextFieldString(textfield, new
PropertyModelString(this, message)));
add(form);
add(new Label(label, new PropertyModelString(this, message)));
}
}

!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN 
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd;
html xml:lang=en lang=en xmlns=http://www.w3.org/1999/xhtml;
head
titleWicket Training - classes for learning wicket/title
/head
body
form wicket:id=form
input type=text wicket:id=textfield /
input type=submit value=submit /
/form
b wicket:id=label/b
/body
/html



On Sun, Oct 5, 2008 at 11:32 AM, eyalbenamram [EMAIL PROTECTED]wrote:


 No, I am using a regular form. the example I brought was to show the JIRA
 report.
 There was a report regarding the regular form but I couldn't find it.

 igor.vaynberg wrote:
 
  are you using a StatelessForm? because in your example you showed a
  regular form
 
  -igor
 
  On Sun, Oct 5, 2008 at 9:04 AM, eyalbenamram [EMAIL PROTECTED]
  wrote:
 
  JIRA:
  https://issues.apache.org/jira/browse/WICKET-1580
 
 
  igor.vaynberg wrote:
 
  where is the bug report?
 
  -igor
 
  On Sun, Oct 5, 2008 at 6:56 AM, eyalbenamram [EMAIL PROTECTED]
  wrote:
 
  Hi
  There is a bug in wicket of a form that uses the GET method
  never calls the onSubmit method.
  I am now using wicket 1.4 m3, and the bug (already reported long time
  ago)
  is still not fixed, though it is said it was fixed. here is my code:
 
 Button backBtn = new Button(back_button, new
  Model(getString(back)));
 
 Form form = new Form(form) {
 public void onSubmit() {
 setResponsePage(prevPage);
 }
 
 protected String getMethod() {
return get;
 }
 };
 form.add(backBtn);
 
 add(form);
 
  What am I doing wrong???
 
  thanks, Eyal.
  --
  View this message in context:
 
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19824816.html
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
  --
  View this message in context:
 
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19826029.html
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context:
 http://www.nabble.com/form-GET-calling-onSubmit-tp19824816p19826373.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




Re: Adding Adobe Media Player in wicket

2008-10-05 Thread newbie_to_wicket

Thanks Jeremy, I'll try on this..
once again thank u.

Cheers
J

Jeremy Thomerson-5 wrote:
 
 The simplest thing is just to put the embed / object tags into the your
 HTML
 file and then adding a wicket:id to the tags that need dynamic parameters.
 Then use a WebMarkupContainer and AttributeModifier to insert the
 appropriate values.
 
 Also, to make it reusable, it could be a panel that takes a couple of
 IModelString instances for the source and vars, etc.
 Something like this:
 
 
 
 
 
 
 
 Obviously, the IModel values below would come from some dynamic source:
 
 WebMarkupContainer flashParam = new
 WebMarkupContainer(flashParamTag);
 WebMarkupContainer flashSrc = new
 WebMarkupContainer(flashSrcTag);
 WebMarkupContainer flashEmbed = new
 WebMarkupContainer(flashEmbedTag);
 
 IModel flashImages = new AbstractReadOnlyModelString(){
 
 @Override
 public String getObject() {
 return var1=foovar2=foo;
 }
 
 };
 
 IModel flashFile = new AbstractReadOnlyModelString(){
 
 @Override
 public String getObject() {
 return foobar.swf;
 }
 
 };
 
 flashParam.add(new AttributeModifier(value, flashImages));
 flashSrc.add(new AttributeModifier(value, flashFile));
 flashEmbed.add(new AttributeModifier(flashvars, flashImages));
 flashEmbed.add(new AttributeModifier(src, flashFile));
 
 add(flashParam);
 add(flashSrc);
 add(flashEmbed);
 
 
 
 -- 
 Jeremy Thomerson
 http://www.wickettraining.com
 
 On Fri, Oct 3, 2008 at 8:25 AM, newbie_to_wicket
 [EMAIL PROTECTED]wrote:
 

 Hi all,

 In our application I've to add Adobe media player to play some video
 clips.

 can any body worked on this, if you worked this kind of situations ,
 please
 give me some small examples .

 I'm very glad if you help in this regard.

 Thanks
 J


 --
 View this message in context:
 http://www.nabble.com/Adding-Adobe-Media-Player-in-wicket-tp19797690p19797690.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


 
 

-- 
View this message in context: 
http://www.nabble.com/Adding-Adobe-Media-Player-in-wicket-tp19797690p19827296.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: AbstractPageStore memory implementation instead of disk

2008-10-05 Thread Matej Knopp
I'd really be interested in how exactly did you come to conclusion
that DiskPageStore writing to disk is the bottleneck. Unless your
filesystem caching is
broken :)
Serialization takes a significant part of request processing, but that
is necessary.

-Matej

On Fri, Oct 3, 2008 at 3:21 PM, Ard Schrijvers
[EMAIL PROTECTED] wrote:
 Hello everybody,

 Did anybody perhaps ever implement a memory version of the
 AbstractPageStore. Currently, I only see a DiskPageStore, which happens
 to be quite a large cpu bottleneck for Windows users AFAICS.

 So, before starting to implement one, just wondering whether somebody
 has experience on a memory page store version,

 Thx for any pointers,

 Regards Ard

 [EMAIL PROTECTED] - [EMAIL PROTECTED] - www.onehippo.com
 -
 Amsterdam - Hippo B.V. Oosteinde 11 1017 WT Amsterdam +31(0)20-5224466
 San Francisco - Hippo USA Inc. 101 H Street, suite Q Petaluma CA
 94952-3329 +1 (707) 773-4646
 -

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



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



Re: which browser is preferrable for Wicket 1.3

2008-10-05 Thread Timo Rantalaiho
On Fri, 03 Oct 2008, John Krasnay wrote:
 Note that this is almost certainly *not* a Wicket issue, since Wicket
 generates the same markup regardless of browsers.

However, in Wicket (ajax) javascript code there are 
differences between different browsers, as in all 
javascript-containing frameworks I suppose.

Best wishes,
Timo


-- 
Timo Rantalaiho   
Reaktor Innovations OyURL: http://www.ri.fi/ 

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



Re: DropDownChoice Model issue

2008-10-05 Thread Timo Rantalaiho
On Sat, 04 Oct 2008, walnutmon wrote:
 I can manually assign the variable at run time using the getModelObject()
 function... I know you can bind through property models, is trying to do so
 with a regular Model() object wrong?

Do you mean this?

  return new DropDownChoice(companies, new Model(company), 
 getCompanies, new ChoiceRenderer(name));

What happens here is that the company object does not get
bound to the model dynamically, but only gets the initial
value from there. Look at the source code of Model -- 
setObject just stores the value internally.

If you want to make the DropDownChoice automatically
update the company value, you can do something like this

  return new DropDownChoicde(companies, new Model() {
  @Override
  public void setObject(Object chosenCompany) {
  company = (Company) chosenCompany;
  }

  @Override 
  public Object getObject() {
  return company;
  }
  }, getCompanies(), new ChoiceRenderer(name));

This is essentially same as using the PropertyModel, only
more explicit and verbose and IDE friendly.

And read the page on models from the wiki, if you didn't
yet.

Note also that often it's better to abstract the access to
domain objects to go via IModel instead of holding direct
references to them, so your company field could actually
be an IModelCompany that you can then use for the
DropDownChoice model directly.

Best wishes,
Timo


-- 
Timo Rantalaiho   
Reaktor Innovations OyURL: http://www.ri.fi/ 

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



Re: using Prototype.js and Scriptaculous with latest version of wicket

2008-10-05 Thread 张伟
I agree with Igor.

if you are looking to generate your ui purely in javascript
you will not be able to take advantage of a lot of wicket components.

And i think you should generate your ui purely in javascript only when the
ui dose not include in the standard Html components.

2008/10/3 Igor Vaynberg [EMAIL PROTECTED]

 there shouldnt be any problems using prototype with wicket.

 however, if you are looking to generate your ui purely in javascript
 you will not be able to take advantage of a lot of wicket components

 -igor

 On Thu, Oct 2, 2008 at 8:18 AM, ilanfox [EMAIL PROTECTED] wrote:
 
  Hello,
 
  I am considering starting a new project (web app) with Wicket.
  This project will be based heavily on JavaScript with Prototype and
  Scriptaculous.
  Most of the UI will be generated via JavaScript and the also the new
 CANVAS
  tag will be used.
  I really need to know if I'm going the right direction. is it safe to
  combine the Prototype lib with Wicket?
  Do I need to fully understand how Wicket works before trying to combine
 it?
  my prior expropriate is mostly with struts1.
 
  Thanks in advance.
  Ilan F
 
 
  --
  View this message in context:
 http://www.nabble.com/using-Prototype.js-and-Scriptaculous-with-latest-version-of-wicket-tp19781402p19781402.html
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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




Re: Radio group, model

2008-10-05 Thread Cristina

A small but important correction... :-)

(e) HTML file: both radio buttons must be under a *span* tag enclosing the
attribute-value pair *wicket:id=options*.

Cristina

-- 
View this message in context: 
http://www.nabble.com/Radio-group%2C-model-tp16678100p19831786.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



Re: which browser is preferrable for Wicket 1.3

2008-10-05 Thread Nino Saturnino Martinez Vazquez Wael



Timo Rantalaiho wrote:

On Fri, 03 Oct 2008, John Krasnay wrote:
  

Note that this is almost certainly *not* a Wicket issue, since Wicket
generates the same markup regardless of browsers.



However, in Wicket (ajax) javascript code there are 
differences between different browsers, as in all 
javascript-containing frameworks I suppose.


  

Yes since the browsers support their own subset of commands.

Best wishes,
Timo


  


--
-Wicket for love

Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


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