title: xslt - adding </tr><tr> every n node?
body: <p>I found an elegant solution for that problem here: <a href="https://stackoverflow.com/questions/3806578">xsl for-each: add code block every n rows?</a></p>
  
  <p>I'd like to understand the xslt code and I was wondering if you could help me to understand it by taking a look at the link provided above. </p>
  
  <p>Basically there are 3 <code>&lt;xsl:template&gt;</code>. To me the first 2 ones are enough to achieve the purpose. However I tried with only 2 <code>&lt;xsl:template&gt;</code> and it doesn't work. In short the third one is required. Here it is:</p>
  
  <pre><code>&lt;xsl:template match="gallery[not(position() mod 6 = 1)]"/&gt;
  </code></pre>
  
  <p>The second template has a mode while the last one has not.</p>
  
  <p>I have no idea when the last one is executed. Could you please help me to figure out it?</p>
  
  <p>Thanks for your help.</p>
  
  <p>Regards,</p>
  
  <p>Roland</p>