title: Check if CSV data is correct with javascript
body: <p>I should check whether the data of a <code>csv</code> file are correct, if they are properly separated by commas even within a string quotes, I do not have to parse because that's already been done by others because the period in which the <code>csv</code> is used to create charts, I have to make only the verification of correctness of the data if user upload a file.</p>
  
  <p>How can I do ?</p>
  
  <p>This is the html code :</p>
  
  <pre><code>&lt;!-- Adding CSV data to the document --&gt;
  &lt;head&gt;
    &lt;script id="cur_data" type="text/csv"&gt;
      Russian Federation, Italy, France, Luxembourg, Greece, Japan, Others
      293, 302, 91, 7, 7, 7, 53
    &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
    &lt;!-- Sections --&gt;
    &lt;div class="section"&gt;
      &lt;h1&gt;Figures&lt;/h1&gt;
        &lt;div id="figure_1" class="picture"&gt;
          &lt;p class="img_block"&gt;
            &lt;img src="#cur_data" class="horizontal_bar_chart" alt="Let's graph it!"&gt;&lt;/img&gt;
          &lt;/p&gt;
          &lt;p class="caption"&gt;Caption of the figure.&lt;/p&gt;
        &lt;/div&gt;
    &lt;/div&gt;
  &lt;/body&gt;
  </code></pre>