|
All in One -
Web
|
|
Written by Administrator
|
|
Friday, 01 May 2009 21:31 |
|
ie does not support canvas tag. when u use excanvas.js it gives an error object doesn't support this property or method ( excanvas.js ) <canvas id="someid"></canvas> this works in firefox , google chrome but not in ie. the solution is: <div id="insertCanvas"></div> <script type="text/javascript"> // new canvas element var canvasElem = document.createElement('canvas'); // you need to add canvasElem to the document before doing anything else. document.getElementById("insertCanvas").appendChild(canvasElem); // if it is IE... if (typeof G_vmlCanvasManager != 'undefined') { // you've to reassign the variable to the new element created by initElement canvasElem = G_vmlCanvasManager.initElement(canvasElem); } canvasElem.setAttribute("id","analiz"); // now you can do getContext on this canvasElem... </script> |
|
Last Updated ( Friday, 15 May 2009 20:08 )
|