I am taking the example from phpexcel
I just tried with passing value in GET Method, I am done with that.
Now i am trying to add image in the a3 coloumn.
<Read my article,
http://www.7codes.info/post/8/export-excel-files-with-images-using-php-excel-library
$objDrawing = new PHPExcel_Worksheet_Drawing(); //create object for Worksheet drawing
$objDrawing->setName('Customer Signature'); //set name to image
$objDrawing->setDescription('Customer Signature'); //set description to image
$signature = $reportdetails[$rowCount][$value]; //Path to signature .jpg file
$objDrawing->setPath($signature);
$objDrawing->setOffsetX(25); //setOffsetX works properly
$objDrawing->setOffsetY(10); //setOffsetY works properly
$objDrawing->setCoordinates($column.$cell); //set image to cell
$objDrawing->setWidth(32); //set width, height
$objDrawing->setHeight(32);
$objDrawing->setWorksheet($objPHPExcel->getActiveSheet()); //save
I solve logo or images insert/showing problem use below code:
$objDrawing = new PHPExcel_Worksheet_Drawing();
$objDrawing->setName('test_img');
$objDrawing->setDescription('test_img');
$objDrawing->setPath('../images/logo.png');
$objDrawing->setCoordinates('A1');
//setOffsetX works properly
$objDrawing->setOffsetX(5);
$objDrawing->setOffsetY(5);
//set width, height
$objDrawing->setWidth(100);
$objDrawing->setHeight(35);
$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());
Specifying coordinates for the image might help, as per the examples and the documentation
$objDrawing->setCoordinates('A3');
Note that an image isn't in a cell/column/row, but overlaid over the main sheet at the same position as that cell/column/row