I have the following piece of HTML:
&l
If you're using JQuery, you shouldn't set the CSS (as the commenters above mentioned). You need to set the attribute so:
$("canvas").attr('width', aWidth); $("canvas").attr('height', aHeight);
works great.