title: node.js readFile with size
body: <p>in php i use</p>
  
  <pre><code> $filename = "a.txt";
   $handle = fopen($filename, "r");
    $heading = fread($handle, 4);
    fclose($handle);
    print $heading;
  </code></pre>
  
  <p>a.txt content</p>
  
  <blockquote>
    <p>hello every one</p>
  </blockquote>
  
  <p>and the output its    </p>
  
  <blockquote>
    <p>hell</p>
  </blockquote>
  
  <p>now in node.js i use</p>
  
  <pre><code>fs = require('fs');
      fs.readFile('a.txt', 'utf8', function (err,data) {
      if (err) {
      return console.log(err);
      }
      console.log(data);
      });
  </code></pre>
  
  <p>its output </p>
  
  <blockquote>
    <p>hello every one</p>
  </blockquote>
  
  <p>how can i use size length on node.js ?</p>