im using google charts for my application. i've to convert the chart into png image and store that image file in local. for that i've used like this but i cant to convert the chart to image in IE8, i should code for IE8 also. is there any other way to convert the chart to png. Is it good way to convert the chart in server side. if so please suggest me to get png image file from the server side in java struts2 application. Thank you in advance.
Asked
Active
Viewed 961 times
1
-
HTML5 – Vinod VT Oct 24 '13 at 09:40
-
3that canvas tag is not working in IE8 – Hariprasath Oct 24 '13 at 09:41
-
1There's [VML](http://msdn.microsoft.com/en-us/library/ee384217%28v=vs.85%29.aspx) for IEs<9, maybe you can use it? – Teemu Oct 24 '13 at 09:49
-
could you have any example code to convert the chart to **image/png;base64** using VML – Hariprasath Oct 24 '13 at 09:57
-
Unfortenately I can't. I have used VML to show 3D CAD models in IE, but it was ten years ago. You could browse the documentation, if you'd find something usefull... – Teemu Oct 24 '13 at 10:07
-
2look into [html2canvas](http://html2canvas.hertzen.com/), it may help. – gwillie Oct 24 '13 at 10:32
-
1is there any options in server side. html2canvas element doesn't support in IE8. – Hariprasath Oct 24 '13 at 10:46
-
I have not tried this, but you might have some luck with the proposed solution here: http://stackoverflow.com/a/11234583/613559 – asgallant Oct 24 '13 at 14:24
-
for the above problem i found the solution please refer [this][1] link [1]: http://stackoverflow.com/questions/19542549/how-to-convert-div-element-to-byte-code/19681698#19681698 – Hariprasath Oct 30 '13 at 12:06
1 Answers
1
If you are also using a <canvas>
-element (as in the post you referenced), you can try using ExplorerCanvas, which brings canvas-functionality to old Internet Explorer version (make sure to use conditional tags for loading).
Another possibility, as Teemu mentioned, is using VML. I haven't found any script to convert canvas to VML, but I did manage to find this: svg2vml. I guess there should also be variants of this that work with canvas.

janvryck
- 26
- 5
-
in ie8 we cannot convert the chart to image and again to byte code using excanvas and vml is a huge process – Hariprasath Oct 30 '13 at 12:04