title: Redirect tag in struts2 jsp page
body: <p>I have a jsp page in struts like this:</p>
  
  <pre><code>&lt;%@taglib prefix="s" uri="/struts-tags" %&gt;
  
  &lt;s:if test="#session.variablename == null" &gt;
      **&lt;s:action name="loginForm" /&gt;**
  &lt;/s:if&gt;
  
  &lt;html&gt;
      &lt;head&gt;
          &lt;script type="text/javascript" src="http://code.jquery.com/jquery-1.7.1.js"&gt;&lt;/script&gt;
      &lt;/head&gt;
      &lt;body&gt;
      &lt;h1&gt;Hello World!&lt;/h1&gt; 
      &lt;s:a href="doctorLogout"&gt;Logout&lt;/s:a&gt; 
   &lt;s:include value="/WEB-INF/doctor/doctorFooter.jsp" &gt;&lt;/s:include&gt;
  </code></pre>
  
  <p>If <code>session</code> is not set, I need to redirect this page to an action in the <code>struts.xml</code> page. I have tried the <code>&lt;jsp:forward /&gt;</code> tag instead of <code>&lt;s:action /&gt;</code>, but the jsp redirects to the error page. Does this have any solution? Does any redirect tag exist in struts2?</p>