I know there are other posts similar to this, but everyone recommends just doing it directly in PHPMyAdmin into MySQL (Which works perfectly, but I need to import through an HTML form to PHP to MySQL.
I would like to have an HTML form that collects a file. Then passes that file to a PHP script and I would like to know if it is possible to simply call a PHP function that converts a comma delimeted .csv file into MySQL and adds it to the database.
Or is the only way to parse the file line by line and add each record?
I haven’t fully tested this, but I don’t see any reason why it wouldn’t work.
Of course you would need to validate the data first.