Hi Kavita,
                 U can follow mvc approach todo  this.
For validations u can do that either through javascript or through a javabean.

For inserting data through jsp,when u click the save button on jsp page ,call
a servlet which inturn will call a session bean.(here session bean is a wrapper
around a entity bean where u'll  write the code for inserting data).

This is the cycle which conforms to mvc2 architecture.

I hope this helps.

Ajay


kavitha ramasamy wrote:

> Hello,
>
>      I want to the following things when I click the save button in
> JSP page
> 1) All front end validations- This I achieved through  JavaScript.
> 2) I need to insert the data in database, This I want to be done through
> JSP page, because all my datas are from session object.
>
> I have the following code to call javascript and I dont know how to
> insert the data through JSP page.
>
> By cllicking the button the validation and insertion of data has to be done.
>
> <input type="button" name="Button" value="Button"  onClick="validation()">
>
> validation() is a javascript function.
>
> If anyone has any idea regarding this, that would be helpful to me.
> Thanks,
> Kavitha
> ________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com
>
> ===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to