title: struts validation occurring when page loads instead of on submit
body: <p>Please forgive me; I am sort of new to struts.  I am having an issue where my validation is occurring when the page loads instead of when i actually submit my form.  I have been googling and scouring through forums all day and haven't had any luck.  I'm obviously doing something incorrectly that should be very easy to nail down, but i haven't found what my issue is yet.</p>
  
  <p>Here is a snippet of my struts.xml:</p>
  
  <pre><code>&lt;action name="*Test" method="{1}" class="testClass"&gt;
              &lt;interceptor-ref name="defaultStack"/&gt;          
              &lt;result name="init"&gt;jsp/index.jsp&lt;/result&gt;
              &lt;result name="input"&gt;jsp/index.jsp&lt;/result&gt;
              &lt;result name="submit"&gt;jsp/results.jsp&lt;/result&gt;
  &lt;/action&gt;
  </code></pre>
  
  <p>As you can see, I have one action that I want to submit to results.jsp if the validation is successful.  Otherwise, i want it to show my index.jsp again.  the pages navigate correctly, as far as i can tell.  I can navigate to app/initTest.action and submit my form and it will take me to the results page and show me my expected results.  My issue lies with the validation.</p>
  
  <p>It seems as though the validation is working, just at the wrong time.  I have a [Action]-validation.xml created in the same location as my class that the action is tied to and when the page loads initially, i see the error message from this xml file on the page already.</p>
  
  <p>Here's what i have in my validation.xml file:</p>
  
  <pre><code>&lt;validators&gt;
      &lt;field name="TestBean.idNumber"&gt;
          &lt;field-validator type="requiredstring"&gt;
              &lt;message&gt;Please select an item.&lt;/message&gt;
          &lt;/field-validator&gt;
      &lt;/field&gt;
  &lt;/validators&gt;   
  </code></pre>
  
  <p>Any assistance you can provide would be greatly appreciated!  </p>
  
  <p>thanks!</p>
  
  <hr>
  
  <p>@nmc,
  I'm trying to visualize the option of using a separate action.  Would it be something like this? If the validation fails, will it redirect back to the original form page?</p>
  
  <pre><code>&lt;action name="*Test" method="{1}" class="testClass"&gt;         
          &lt;result name="init"&gt;jsp/index.jsp&lt;/result&gt;
          &lt;result name="submit"&gt;initTestResults&lt;/result&gt;
  &lt;/action&gt;
  &lt;action name="*TestResults" method="{1}" class="testClass2"&gt;
          &lt;interceptor-ref name="defaultStack"/&gt;          
          &lt;result name="init"&gt;jsp/indexResults.jsp&lt;/result&gt;
          &lt;result name="input"&gt;jsp/indexResults.jsp&lt;/result&gt;
  &lt;/action&gt;
  </code></pre>
  
  <p>I'm trying to figure out which option is better for my purpose.</p>
  
  <p>Thanks for your input.</p>