I'm writing a php script where I call
$lines = file('base_list.txt');
to break a file up into an array. The file has over 100,000 lines in it, which should be 100,000 elements in the array, but when I run
print_r($lines);
exit;
the array only contains 7280 elements.
So I'm curious, WTF? Is there a limit on the amount of keys an array can have? I'm running this locally on a dual-core 2.0Ghz with 2GB of RAM (Vista & IIS though); so I'm a little confused how a 4MB file could throw results like this.
Edit: I have probably should have mentioned that I had previously set memory_limit to 512MB in php.ini as well.