Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

How to invoke a web page on logout action

 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I have logout action mapping as follows in my struts-config.xml:
<action
path="/Logout"

type="com.xxx.yy.dd.mm.web.action.LogoutAction">
<forward name="success" path="/index.jsp"/>
<forward name="failure" path="/LogoutFailed.jsp"/>
</action>
My problem is I now have to invoke a web page (www.google.com) instead of login page.. Can someone enlighten me a novice in struts.. Much appreciated.
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just make a forward that points to Google. There are a couple of requirements that you must follow when forwarding to a an outside website:
  • You must specify the full URL including the http://
  • You must specify redirect="true"
  • so your forward would look like this:

    [ May 30, 2007: Message edited by: Merrill Higginson ]
     
    catch it before it slithers away! Oh wait, it's a tiny ad:
    Thread Boost feature
    https://coderanch.com/t/674455/Thread-Boost-feature
      Bookmark Topic Watch Topic
    • New Topic