title: PHP Multi dimentional array
body: <p>This is my code. I don't know why it is not working.
  I was trying to print my table with php for loop, but nothing shows up on the website.<a href="https://i.stack.imgur.com/Q6pV3.png" rel="nofollow noreferrer">Nothing</a></p>
  <p>This is the two-dimentional array that I was trying to print out.</p>
  <pre><code> &lt;!--Arrays of weapons--&gt;
   &lt;?php
   $weapons = array(
   array(&quot;M4A1&quot;,1,78906,&quot;TUCKER, LISBETH&quot;,&quot;SPC&quot;),
   array(&quot;M4A1&quot;,2,78915,&quot;HATHAWAY, HANNAH&quot;,&quot;1LT&quot;),
   array(&quot;M4A1&quot;,3,78933,&quot;HARRIS, LEE&quot;,&quot;SFC&quot;),
   array(&quot;M4A1&quot;,4,78934,&quot;WELCH, BRAD&quot;,&quot;SSG&quot;),
   array(&quot;M9&quot;,1,1167552,&quot;BLAND, MARGARET&quot;,&quot;CPT&quot;),
   array(&quot;M249&quot;,1,101032,&quot;TYSON, MICHELLE&quot;,&quot;1SG&quot;),
   array(&quot;M249&quot;,2,101038,&quot;MEDINA, TOBIAS&quot;,&quot;SPC&quot;),
   array(&quot;M240B&quot;,1,104104,&quot;COSTA, JOSHUA&quot;,&quot;SSG&quot;),
   array(&quot;M2A1&quot;,1,1863848,&quot;GARCIA, RIGOBERTO&quot;,&quot;SSG&quot;),
   array(&quot;MK-19&quot;,1,19369,&quot;NEUPANE, KISHOR&quot;,&quot;SPC&quot;)
   );
   ?&gt;
  </code></pre>
  <p>This is the code that I was trying to use to print out.</p>
  <pre><code>&lt;!--Create the Weapons List Table--&gt;
   &lt;table border =&quot;1&quot;&gt;
   &lt;tr&gt;
    &lt;th&gt;Type&lt;/th&gt;
    &lt;th&gt;Buttstock #&lt;/th&gt;
    &lt;th&gt;Serial #&lt;/th&gt;
    &lt;th&gt;Name&lt;/th&gt;
    &lt;th&gt;Rank&lt;/th&gt;
   &lt;/tr&gt;
   &lt;!--Put two-dimentinal arrays in the table--&gt;
   &lt;?php foreach ($row = 0; $row &lt; 10, $row++) {?&gt;
    &lt;tr&gt;
    &lt;?php for ($col = 0; $col &lt; 5, $col++) {?&gt;
     &lt;td&gt;&lt;?php echo $weapons[$row][$col];?&gt;&lt;/td&gt;
    &lt;?php }?&gt;
    &lt;/tr&gt;
    &lt;?php }?&gt;
   &lt;/table&gt;
  </code></pre>