0

I am having issues with excanvas not rendering in IE8. Here is where I initialize the canvas.

var canvas = document.getElementById("map");
if (typeof (G_vmlCanvasManager) != 'undefined') {
    canvas = G_vmlCanvasManager.initElement(canvas);
}
var ctx = canvas.getContext("2d");
ctx.fillStyle = "#656600"; // sets colors of counties
ctx.strokeStyle = "#ff0000";
ctx.flobalAlpha = 0.33; // set transparency

<img name="texasmapofcounties" src=../texas-map-of-counties.jpg"style="position: absolute; height: 719px; width: 800px; left: 0px; top: 0;" alt="map of texas counties" />
<canvas id="map" width="800" height="719" style="position: absolute; left: 0px; top: 0; opacity: 1;"></canvas>
<div id="map_blind"  style="position: absolute; height: 719px; width: 800px; left: 0px; top: 0;"></div>
<img name="texasmapofcounties" src="../texas-map-of-counties.jpg" width="800" height="719" border="0" id="texasmapofcounties" usemap="#m_texasmapofcounties" alt="" style="position: absolute; height: 719px; width: 800px; left: 0px; top: 0; -moz-user-select: none; opacity: 0;" />    

The purpose of the site is if a county in the state of Texas has a "Famous Tree" in it the county is colored green. Then a user is able to select the county and click it for a pop up list of trees. The functionality works in IE7 IE9, FF, Chrome,etc... Its just IE8 and Excanvas are not working properly.

Any help will be appreciated!

Jeremy
  • 1
  • 1
  • 1
    Duplicate of these questions : http://stackoverflow.com/questions/2444456/excanvas-does-not-work-in-ie8-at-all http://stackoverflow.com/questions/941170/does-anyone-could-make-excanvas-work-in-ie-8-with-jquery – Michael Lumbroso Aug 20 '12 at 15:31
  • can you be more specific on what issues you are having? Does the canvas initialise correctly? also do you run the script before you output the markup (or before the DOM is ready?) – Peter Pajchl Aug 20 '12 at 15:35
  • I used the solution from http://stackoverflow.com/questions/941170/does-anyone-could-make-excanvas-work-in-ie-8-with-jquery However, when i view the source it does not show that the element has been appended to the div. – Jeremy Aug 24 '12 at 19:59
  • Here is the link to the site http://tfsweb.tamu.edu/websites/FamousTreesOfTexas/Explore_Our_Trees/?cat=County – Jeremy Aug 24 '12 at 20:00

0 Answers0