javascript - jqPlot legends for donut chart not displaying color-swatches/box -


i have simple problem

code :

$(document).ready(function(){   var s1 = [['status',600], ['pictures',800], ['starred',140], ['comments',200]];   //var s2 = [['a', 8], ['b', 12], ['c', 6], ['d', 9]];    var plot3 = $.jqplot('chart3', [s1], {     seriesdefaults: {       // make donut chart.       renderer:$.jqplot.donutrenderer,       rendereroptions:{         // donut's can cut slices pies.         slicemargin: 3,         // pies , donuts can start @ arbitrary angle.         startangle: -90,         showdatalabels: true,         // default, data labels show percentage of donut/pie.         // can show data 'value' or data 'label' instead.         datalabels: 'label'       }     },      grid: {     drawgridlines: true,        // wether draw lines across grid or not.       // *color of grid lines.     background: 'white',      // css color spec background color of grid.     bordercolor: 'white',     // css color spec border around grid.         shadow: false            }  ,legend: { show:true, location: 'e' }          }); }); 

now legend show not in way should shows ..enter image description here

no colours , no box. doing wrong. did documents said.. anyone?

this happens when forget include jqplot css file.

make sure have included <link rel="stylesheet" href="https://bitbucket.org/cleonello/jqplot/raw/b5a7796a9ebf/src/jquery.jqplot.css" type="text/css"/>

and things should work out you.

well, if have included jqplot css file, have check it, , spot problem.

hope helps.


Comments

Popular posts from this blog

php - Submit Form Data without Reloading page -

linux - Rails running on virtual machine in Windows -

php - $params->set Array between square bracket -