You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by "Mathias P.W Nilsson" <ma...@snyltarna.se> on 2008/04/05 10:48:23 UTC

Form processing question

Hi!

I have this simple form that has a property model and in the onSubmit I
handle the data. Is this the correct way of doing it? Sometimes it takes a
little time for the form to redirect after post.

If doing this in php I would have an intermediate page that would handle the
process so the user would see right away that something happend. Is this the
way you do it?

Form form = new Form( "keywordForm" );
        form.add( keywordView );
        form.add( new Button( "addKeywords" ){
        	@Override
        	public void onSubmit(){
        		
        		DataSheet dataSheet = getDataSheetDao().getSheet(sheet);
        		
        		for( DataSheetMetaData meta : keywords ){
        			
        			if( meta.getMeta() != null ){
        				meta.setDataSheet(dataSheet);
        				getDataSheetDao().update( meta );
        			}
        		}
        		
        		setResponsePage( new DocumentPage( sheet ) );
        	}
        });
        
        
        add( form );
-- 
View this message in context: http://www.nabble.com/Form-processing-question-tp16510892p16510892.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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