aspose file tools*
The moose likes Struts and the fly likes On clicking submit button , a new window should open up. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "On clicking submit button , a new window should open up." Watch "On clicking submit button , a new window should open up." New topic
Author

On clicking submit button , a new window should open up.

Galaxie Atlboy
Greenhorn

Joined: Jun 01, 2009
Posts: 2
I have 5 different submit buttons in my JSP page each linked to a different Action method in Java class. I am using Struts 2 frame work. After filling the JSP form fields, when one of the submit button is clicked a new window should pop- up which contains info from the earlier JSP which was filled.

Example. If 1.jsp has Name, Address, Phone , Age, Type of Occupation etc fields. When I click on one of the submit buttons, a new window say 2.jsp should pop-up , which contains Name, Address and Phone filled in 1.jsp. It is kind of a preview page to see how the final page will look after saving. Also the info filled in 2.jsp should remain as it is , since if someone doesnt like its preview they can still change the info in 1.jsp

Can anyone help me?

Currently in my 1.jsp Ihave

<a target="_blank" href=<s:url value="myview" /><s:submit value="myview" title="myview" action="myview" />>
</a>




Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61648
    
  67

Please be sure to ask Struts questions in the Struts forum. I have moved this post there for you.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Galaxie Atlboy
Greenhorn

Joined: Jun 01, 2009
Posts: 2
Thanks ..... it was my first post.....
Shailesh Narkhede
Ranch Hand

Joined: Jul 10, 2008
Posts: 368
You can call one JS function on click of button(that is normal button not submit type) in that function submit form and after that you can use window.open() to open new window.

you can get help from THIS link


Thanks,
Shailesh
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: On clicking submit button , a new window should open up.