• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Struts Forward in to new Window

 
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Yall,

I would like to have a forward open up in a new window. I.e. In my struts-config.xml:


<action path="/quote"
name="quoteForm"
type="com.mycompany.configurator.view.quote.QuoteAction"
scope="request" unknown="false">
<forward name="success" path="Tiles.QuotePage" />
<forward name="print" path="/WEB-INF/jsp/print.jsp" />
</action>

I would like print.jsp to open up in a New Window.

How would I do this without using javascript? There must be an easy way.

Any help would be greatly appreciated.

Cheers,

Cory
 
Bartender
Posts: 1845
10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This isn't a decision you can make at the server side.

When you click the link on the page, it has to know at that time where it will load the response into.
All the server does is send back a response, and leaves it to the client to put the response where it will - replace the current page, in a new window etc etc.

You can do in struts by setting a target="_blank" on your html:form or html:link tag.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic