title: Smarty - How to add values from my form to mysql query?
body: <p>I don't know how to pass values from form to mysql query using smarty.</p>
  
  <p>Code body.tpl:</p>
  
  <pre><code>&lt;form action="" name="training" id="training"&gt;
    &lt;select name="city"&gt;
      &lt;option value="ostrava"&gt;Ostrava&lt;/option&gt;
    &lt;/select&gt;
    &lt;input type="text" name="date_start" id="date_start" value="" /&gt;
    &lt;input type="submit" /&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Mysql query:</p>
  
  <pre><code>SELECT * FROM table WHERE city="&lt;value from city&gt;" AND date_start="&lt;value from date_start&gt;"; 
  </code></pre>