anny Posted September 29, 2010 Share Posted September 29, 2010 hello everyone, please anyone can help me how to read data of excel file in php Link to comment https://forums.phpfreaks.com/topic/214696-reading-data-from-excel-file-in-php/ Share on other sites More sharing options...
yaMz Posted September 29, 2010 Share Posted September 29, 2010 http://sourceforge.net/projects/phpexcelreader/ Link to comment https://forums.phpfreaks.com/topic/214696-reading-data-from-excel-file-in-php/#findComment-1117061 Share on other sites More sharing options...
anny Posted September 30, 2010 Author Share Posted September 30, 2010 i download this file already but it does not work nothing is showing i dnt know y:( plz help me i put the folder(which contain excel reader) in htdocs & ,my script test.php like C:\apache2triad\htdocs\ReadingEXCELfile\Excel\test.php code is <html> <head><title></title> <body> <table> <?php // include class file include 'reader.php'; // initialize reader object $excel = new Spreadsheet_Excel_Reader(); // read spreadsheet data $excel->read('Book1.xlsx'); // iterate over spreadsheet cells and print as HTML table $x=1; while($x<=$excel->sheets[0]['numRows']) { echo "\t<tr>\n"; $y=1; while($y<=$excel->sheets[0]['numCols']) { $cell = isset($excel->sheets[0]['cells'][$x][$y]) ? $excel->sheets[0]['cells'][$x][$y] : ''; echo "\t\t<td>$cell</td>\n"; $y++; } echo "\t</tr>\n"; $x++; } ?> </table> </body> </head> </html> Link to comment https://forums.phpfreaks.com/topic/214696-reading-data-from-excel-file-in-php/#findComment-1117488 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.