Convert excel to csv and import data to php -


i need import data excel php, heard it's hard, need convert excel file csv. have problem, can't convert successfully, when trying error message: errorcsv

my original excel file looks like: original

and after convert csv: afterconvert

what's problem? need convert , keep same format.

my php file csv reading looks like:

<?php $row = 1; if (($handle = fopen("test.csv", "r")) !== false) {     while (($data = fgetcsv($handle, 1000, ",")) !== false) {         $num = count($data);         echo "<p> $num fields in line $row: <br /></p>\n";         $row++;         ($c=0; $c < $num; $c++) {             echo $data[$c] . "<br />\n";         }     }     fclose($handle); } ?>  

and result how looks after reading in php: example

so need ideas how convert xls csv without loosing format or how import data excel file php. can me, please? thank you.

this phpexcel library have problems (memory / time ) loading big files. if file not big, phpexcel solution, else maybe have try loading data in .csv format directly.


Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

c++ - End of file on pipe magic during open -