Hi All,
My requirement is,i have one
JSP page ,namely welcome.jsp.in that there is one button "addcontact".when i click on that one,a pop-up of addcontact.jsp should come.and after entering the details and clicks on ADD button ,that popup should vanish and whatever the contacts we have added before should come to the contact list automatically!
This is my code (welcome.jsp):
%@ taglib uri="/tags/struts-bean" prefix="bean" %
%@ taglib uri="/tags/struts-html" prefix="html" %
%@ taglib uri="/tags/struts-logic" prefix="logic" %
%@page import="java.util.*" %
html
head
title welcome page /title
/head
script type="text/javascript"
function addcontact()
{
addcontactwindow=window.open("addcontact.jsp","addcontactwindow","status=1,scrollbars=1,resizable=1");
addcontactwindow.moveTo(2,2);
}
/script body
html:errors/
h2 welcome /h2 %=session.getAttribute("ausername")%
h2 MyProfile /h2
NAME %=session.getAttribute("ausername")%
EMAIL %=session.getAttribute("aemail")%
h2 Contacts /h2
logic:iterate id="person" name="arll"
logic:iterate id="details" name="person"
bean:write name='details' property='key'
bean:write name='details' property="value"
/logic:iterate
/logic:iterate
INPUT TYPE="button" VALUE="Add Contact" onklick="addcontact()"
/body
/html
With this code ,when i clicks on add button,another window is coming and saying that"you are successfully added the contact",
here what i want is instead of that,that popup should close and that contacts must automatically adds in the contact list.
How can i do that?give me a suggestion
Regards,
sreelakshmi.