Is there a way to use fgetcsv to open on a particular row?
I have a really big csv and would like to run around 100 lines at a time via ajax. I can easily stop the while loop, but how would I open on a particular line? Or is this impossible?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There’s no simple way to start reading at row 100, but what you can do is read/set the position in the file like this:
Now it’s just a matter of preserving this position between page calls.