title: PHP File_Get_Contents()
body: <p>I have a very long text file (300 000 characters) with data delimited by a comma.</p>
  
  <p>aaa,bbb,ccc,ddd,eee,ffff,gg,hhhhh,ii,j,kkkkkkkkkkkkk,l,mm</p>
  
  <p>I'd like to populate the data into a string but by parts. For example, the first 100 pieces of data, then the next. Take note that the length of each piece of data varies unpredictably.</p>
  
  <p>Is there a quick way to do this? I'd like to populate the data into a string in parts because I don't want to use too much memory at a time. So somewhat like a loop:</p>
  
  <pre><code>for ($counter = 0; $counter &lt; $somenumber; $counter++) {
  // (1) extract counter-th 100 pieces of data to string
  // (2) explode string with , as delimiter so I can obtain an array
  // (3) do something to this array
  }
  </code></pre>
  
  <p>Can I use file_get_contents? Or what can I use?</p>