I have a csv file uploaded and data read into an array .The valid data is stored in the array
as associative array indexed from 0-4000 records
Array
(
[0] => Array
(
[uname] => uname1
[name] => fullname1
[email] => uname1@email.com
)
[1] => Array
(
[uname] => uname2
[name] => fullname2
[email] => uname2
)
[2] => Array
(
[uname] => uname3
[name] => fullname3
[email] => uname3@email
)
[3] => Array
(
[uname] => uname3
[name] => fullname3
[email] => uname3@email
)
..
...
[3999] => Array
(
[uname] => uname3
[name] => fullname3
[email] => uname3@email
)
)
How can i insert so many records because the $array is stored in variable when i click the submit the $array is reset to null.
How can I approach this without using database, any solution available?
Are you trying to say you’re overflowing the 64KB limit of the
<FORM>when you submit it? Make sure you’re usingmethod="POST"andencoding="multipart/form-data".It’s also possibly, but highly unlikely with 4000 records, that you’re exceeding the
post_max_sizeandupload_max_filesizeparameters in yourphp.inifile. If you’re secretly trying to post 50 million email addresses instead then that’s likely your problem.If that doesn’t help, then you need to clarify what you’re trying to accomplish, because we’re left guessing. 😉