title: PHP/HTML - Setting a cap on a input using a variable in php?
body: <p>I'm looking for a way to limit the amount of an input like this:</p>
  
  <pre><code>&lt;?php
  $Maximum = 10;
  ?&gt;
  &lt;form action="" method="post"&gt;
       Quantity: &lt;input type="number" value="0" min="0" max=$Maximum step="0" data-number-to fixed="2" data-number-stepfactor="100"  name="Quantity" /&gt;
      &lt;input type="submit"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>But the Maximum would change depending on the database so it could be anywhere from 1 to 1000+ etc. Is there any possible way I could do this just limiting in the HTML or would I have to just use a PHP <code>if</code> statement after the number is submitted?</p>