title: PHP Insert Multiple Records if User select Multiple Options From Form
body: <p>I know this might be beyond the scope of this lesson but I really need help. I have a form  on my website for users to fill out and the database saved into the MySQL database table. However, I want to be able to select multiple rows when a user select multiple options from the Select field in the form. Can I get any help, please. I'm dying here.  </p>
  
  <pre><code>&lt;h3&gt;Create Order&lt;/h3&gt;
  &lt;form action="" method="post"&gt;
  &lt;p&gt;Product: &lt;input type="text" name="product_id" value=""&gt;&lt;p&gt;
  
  &lt;p&gt;Quantity:  &lt;input type="text" name="quantity" value=""&gt;&lt;/p&gt;
  
  &lt;p&gt;Category: &lt;select name="category" multiple&gt;
  &lt;option value="1"&gt;Business Card&lt;/option&gt;
  &lt;option value="2"&gt;Flyer&lt;/option&gt;
  &lt;option value="3"&gt;Brochure&lt;/option&gt;
  &lt;/select&gt;&lt;/p&gt;
  
  &lt;/form&gt;
  
  
  Insert into `orders` (product_id, quantity, category_id) Value (product_id, quantity, category_id)
  </code></pre>
  
  <p>If the user select more than one category, I want the order to be save as individual orders. I hope this explains better. </p>