Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to display image in popup window using struts & javascript

843838Oct 2 2005 — edited Oct 2 2005
I would like to display the image of a person both in the original page as well as the popup window. I have tried doing using the following ;

I have the tried following in my jsp page to display the image

<td class=<%=classname%>><html:link href="GotoImage.do?action=DisplayImage" paramId="person_Id" paramName="personbean" paramProperty="person_Id" onclick="PopupImage('GotoImage.do?action=DisplayImage','defect_Id')"><bean:write name="personbean" property="personName"/></html:link></td>

The following is my javascript

</script>
<script language=javascript>
function PopupImage(target)
{
var PopupWindow=null;

PopupWindow=window.open('<html:form action="GotoImage.do?action=DisplayImage&target" />','mywin','left=20,top=20,width=500,height=500,toolbar=1,resizable=0');
PopupWindow.focus();
}
</script>

However I'm getting error in my popup window but not in original page.

Please any help is most welcomed.

Josh
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 30 2005
Added on Oct 2 2005
1 comment
305 views