First of all I use this class for creating excel files via XML: https://github.com/oliverschwarz/php-excel
My headers that I want to export to Excel;
$headers = array("A","B","C");
My arrays that I want to export to Excel;
$example = array("a1","a2","a3");
$example2 = array("b1","b2","b3");
$example3 = array("c1","c2","c3");
Then I merge my arrays in 1 array with these codes;
$result = array($headers,$example,$example2,$example3);
In conclusion I start the action;
$xls = new Excel_XML('UTF-8', false, 'Test');
$xls->addArray($result);
$xls->generateXML('xls-file');
After that, these class creates a XLS file as expected but; that XLS file scheme is unexpected because of my arrays's types. So I need help my friends, what should I do? Thanks...
Output is like that;
A_|__B__|_C
A1|__A2_|_A3
B1|__B2_|_B3
C1|__C2_|_C3
Output I desire is like that;
A_|__B__|_C
A1|__B1_|_C1
A2|__B2_|_C2
A3|__B3_|_C3