Open RainOGD opened 7 years ago
class ExcelDataController extends Controller { public function readAndSaveAction() { $filename = $this->container->getParameter('xls_fixture_absolute_path'); $phpExcelObject = $this->get('phpexcel')->createPHPExcelObject($filename); // $writer = $this->get('phpexcel')->createWriter($phpExcelObject, 'Excel5');
for ($i = 1; $i <= 10; $i++){ $value = $phpExcelObject->getActiveSheet()->getCell('C' . $i)->getValue(); var_dump($value); } die;
// $writer->save($filename); } }
I get bad characters when I'm trying to read xlsx file with russian characters. How to resolve this?
class ExcelDataController extends Controller { public function readAndSaveAction() { $filename = $this->container->getParameter('xls_fixture_absolute_path'); $phpExcelObject = $this->get('phpexcel')->createPHPExcelObject($filename); // $writer = $this->get('phpexcel')->createWriter($phpExcelObject, 'Excel5');
// $writer->save($filename); } }
I get bad characters when I'm trying to read xlsx file with russian characters. How to resolve this?