title: Uploaded file size says undefined
body: <p>I'm trying to get the size of an uploaded image in JQuery. I created an event for the change of the form and inserted the following in it:</p>
  
  <pre><code>console.log($(this)[0].size);
  </code></pre>
  
  <p>The output of that is undefined. What am I doing wrong, and how can I get the uploaded image size?</p>
  
  <p><a href="http://jsfiddle.net/ye78Lqp0/1/" rel="nofollow"><h3>JSFiddle</h3></a></p>
  
  <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>$(document).ready(function() {
    $('#uploadform').on('change', function(evt) {
      console.log($(this)[0].size);
    });
  });</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"&gt;&lt;/script&gt;
  &lt;form action="upload.php" enctype="multipart/form-data" method="POST" id="uploadform"&gt;
    &lt;input id="openFile" name="img" type="file" /&gt;
  &lt;/form&gt;</code></pre>
  </div>
  </div>
  </p>