Hello,
        I am using URL :

$url=    "
http://chart.googleapis.com/chart?cht=lc&chs=400x240&chxt=x%2Cy&chxl=0%3A%7C2004%7C2005%7C2006%7C2007&chdlp=r&chdl=Sales%7CExpenses&chco=3399CC%2C80C65A&chxr=1%2C0%2C1170&chd=e%3A2s..vC4V%2CV4ZKfudi
"

 and i want to download image in .png format, so i am using code :


header('Content-Type: image/png');
header('Content-Disposition: attachment; filename="chart.png"');
$image = file_get_contents($url);
header('Content-Length: ' . strlen($image));
echo $image;


but echo image showing error. Please tell me how i can resolve this
issue .

Error: Not a PNG file.

Regards
Amit Sharma

-- 
You received this message because you are subscribed to the Google Groups 
"Google Chart API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-chart-api?hl=en.

Reply via email to