<?php
require ("Classes/PHPExcel.php");
require ("Classes/PHPExcel/IOFactory.php");
//include ("Classes/IOFactory.php");
$excel2 = PHPExcel_IOFactory::createReader("Excel2007");
echo "start";
$excel2 = PHPExcel_IOFactory::load('test.xls');
echo "loading working";
echo "<br/>";
$excel2->setActiveSheetIndex();
$excel2->getActiveSheet(0)
->setCellValue("G1", "Test tag no.")
->setCellValue("G2", "Test service")
$file = PHPExcel_IOFactory::createWriter($excel2, "Excel5");
echo "edit working";
echo "<br/>";
$name = ('test.xls');
//$file->save("php://output");
//echo "Saving working";
//exit;
$file->save($name);
echo "Saving working";
?>