sending image to excel

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
   can any one help me to solve this problem.

I am trying to send HTML data to excel.But the HTML
data
contains image which i could not able to get in excel
sheet.

The Code is:


echo ("<html><title>Report</title><body>");
		echo ("<table width='100%' class='header' border='0'
cellpadding='0' cellspacing='1'
bordercolor='#B6C7E5'>");
		if (isset ($image) && $image != '') {
			
			echo (header("Content-type: ", "image/png"));
			echo ("<tr><td><IMG
SRC='http://localhost/workspace/reports/includes/templates_c/{$image}'></td></tr>");
		}
		echo (header("Content-Type:
application/octet-stream\n"));
		echo (header("Content-Disposition: attachment;
filename=extraction.xls"));
		echo (header("Content-Transfer-Encoding:
binary\n"));
		echo ("<tr>");
		for ($i = 0; $i < count($data); $i ++) {
			echo ("<td width='20%' height='30'
bgcolor='#F2F4F8'>"."<div
align='center'>{$data[$i]}</div>"."</td>");
		}
		echo ("</tr>");
		echo ("<tr>");
		for ($j = 0; $j < count($fields[0]); $j ++) {
			$i = 0;
			while ($i < count($fields)) {
				echo ("<td bgcolor='#EEEEEE'
align='left'>{$fields[$i][$j]}&nbsp;</td>");
				$i ++;
			}
			echo ("</tr>");
			echo ("<tr>");
		}
		echo ("</tr>");
		echo ("</tr>");
		echo ("</table>");
		echo ("</body></html>");


		
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - 250MB free storage. Do more. Manage less. 
http://info.mail.yahoo.com/mail_250


PHP Data object relational mapping generator - http://www.meta-language.net/ 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php-objects/

<*> To unsubscribe from this group, send an email to:
    php-objects-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 




[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Soap]     [Kernel Newbies]     [Yosemite]     [Yosemite Campsites]

  Powered by Linux