Plot not showing on IE6 or IE8 (IE7 not tested)

92 views
Skip to first unread message

Zico

unread,
Apr 12, 2011, 2:19:06 PM4/12/11
to jqplot-users
Hi,

Plot shows no problem on Firefox (well of course, right? :) )

Does not show on IE6; does show on IE8 *only* if I disable
Compatibility view.

Jquery itself seems to be running, since I put a Warning that
JavaScript is disabled, and erase that element from a jquery
routine.

What would be the aspects to watch for?

Here are the relevant portions of the code:

Inside <head>:
<script src="/scripts/jquery.min.js" type="text/javascript"></
script>
<script src="/scripts/jquery.jqplot.min.js" type="text/
javascript"></script>
<script src="/scripts/excanvas.js" type="text/javascript"></
script>

<link rel="stylesheet" type="text/css" href="/styles/
jquery.jqplot.min.css" />

<script type="text/javascript">
function plot_elo()
{
$(".warningnojs").remove();
$.jqplot.config.enablePlugins = true;
var puntos =
[1565.71,1567.49,1564.46,1561.47,1563.26,1565.01];
var interval = 5;
if (puntos.length <= 20)
{
interval = 1;
}
else if (puntos.length <= 40)
{
interval = 2;
}
plot1 = $.jqplot('elo_chart', [puntos], { title:'ELO en
Juegos Recientes', series:[ {lineWidth:1,showMarker:(puntos.length <
10)} ], axes:{xaxis:{min:0, max:puntos.length+1,
tickInterval:interval, tickOptions: { formatString:'%d'}}} });
}
</script>

And somewhere inside <body>:

<h3>ELO:</h3>
<div id="elo_chart" style="text-align:left; width:760px;">
<p class="warningnojs" style="color:#c00;"><strong>JavaScript
seems to be disabled ... etc. etc.</strong></p></div>
<script type="text/javascript">plot_elo();</script>


Thanks for any tips,
-Zico
Reply all
Reply to author
Forward
0 new messages