karen m Report post Posted August 19, 2011 I am experiencing problems getting the data to render for linked charts. I reviewed the document for FusionCharts and made references to configureLinks JavaScript function but I cannot find an example of how to include the configureLinks when using JSTL to render the chart content. Below is my JSON message being generated (Note: I switched from newchart-json- to newchart-xml because newchart-json wasn't working at all; now I get a message stating there is no data to display). {"chart":{"caption":"Web Orders", "showLabels":"0", "enablesmartlabels":"0", "showlegend":"1", "pieRadius":"90", "showPercentValues":"1", "showBorder":"1", "baseFont":"Verdana, Geneva, Arial, Helvetica, sans-serif", "baseFontSize":"10", "bgColor":"CC9900,FFFFFF", "canvasbgColor":"CC9900,FFFFFF" }, "data":[{"label":"Total Web Orders","value":1747,"color":"FF0000","link":"newchart-xml-WebOrders1"}, {"label":"Total Non-Web Orders","value":198,"color":"FF0000","link":"newchart-xml-TotalsOrders1"} ], "linkeddata":[{"id":"WebOrders1", "linkedcharts":{"chart":{"caption":"Web Orders", "showLabels":"0", "enablesmartlabels":"0", "showlegend":"1", "pieRadius":"90", "showPercentValues":"1", "showBorder":"1", "baseFont":"Verdana, Geneva, Arial, Helvetica, sans-serif", "baseFontSize":"10", "bgColor":"CC9900,FFFFFF", "canvasbgColor":"CC9900,FFFFFF" }, "data":[{"label":"NE","value":767}, {"label":"MA","value":527}, {"label":"MW","value":307}, {"label":"SE","value":146} ] } }, {"id":"TotalsOrders1", "linkedcharts":{"chart":{"caption":"Total Orders", "showLabels":"1", "showlegend":"1", "showBorder":"1", "baseFont":"Verdana, Geneva, Arial, Helvetica, sans-serif", "baseFontSize":"10", "bgColor":"CC9900,FFFFFF", "canvasbgColor":"CC9900,FFFFFF" }, "categories":[{"category":[{"label":"Total Web Orders"}, {"label":"Total Non-Web Orders"}, {"label":"Total Orders"} ] } ], "dataset":[{"seriesname":"NE", "data":[{"value":767}, {"value":64}, {"value":831} ] }, {"seriesname":"MA", "data":[{"value":527}, {"value":69}, {"value":596} ] }, {"seriesname":"MW", "data":[{"value":307}, {"value":34}, {"value":341} ] }, {"seriesname":"SE", "data":[{"value":146}, {"value":31}, {"value":177} ] } ] } ] } JSP Snippet: <c:set var="pathToChart" value="<%=chartPath%>"/> <c:set var="pos" value="0"/> <br/> <table border="0" cellpadding="1" cellspacing="1" width="800px" class="tblBox"> <c:forEach var="chart" items="<%=charts%>"> <c:set var="name" value="${chart.chartName}"/> <c:if test="${pos eq 0}"> <tr> </c:if> <td> <fc:render chartId="${chart.id}" swfFilename="${pathToChart}/${name}" debugMode="false" jsonData="${chart.json}" width="360" height="250"/> </td> <c:choose> <c:when test="${pos eq 2}"> <c:set var="pos" value="0"/> </tr> </c:when> <c:otherwise> <c:set var="pos" value="${pos + 1}"/> </c:otherwise> </c:choose> </c:forEach> <c:if test="${pos < 2}"> <c:forEach var="i" begin="${pos}" end="2" step="1"> <td> </td> </c:forEach> </tr> </c:if> </table> Based on your documentation configureLink will allow me to configure each child chart to user a certain chart swf file. Share this post Link to post Share on other sites
karen m Report post Posted August 19, 2011 Put under wrong topic. Moving to general help section. I am experiencing problems getting the data to render for linked charts. I reviewed the document for FusionCharts and made references to configureLinks JavaScript function but I cannot find an example of how to include the configureLinks when using JSTL to render the chart content. Below is my JSON message being generated (Note: I switched from newchart-json- to newchart-xml because newchart-json wasn't working at all; now I get a message stating there is no data to display). {"chart":{"caption":"Web Orders", "showLabels":"0", "enablesmartlabels":"0", "showlegend":"1", "pieRadius":"90", "showPercentValues":"1", "showBorder":"1", "baseFont":"Verdana, Geneva, Arial, Helvetica, sans-serif", "baseFontSize":"10", "bgColor":"CC9900,FFFFFF", "canvasbgColor":"CC9900,FFFFFF" }, "data":[{"label":"Total Web Orders","value":1747,"color":"FF0000","link":"newchart-xml-WebOrders1" }, {"label":"Total Non-Web Orders","value":198,"color":"FF0000","link":"newchart-xml-TotalsOrders1" } ], "linkeddata":[{"id":"WebOrders1", "linkedcharts":{"chart":{"caption":"Web Orders", "showLabels":"0", "enablesmartlabels":"0", "showlegend":"1", "pieRadius":"90", "showPercentValues":"1", "showBorder":"1", "baseFont":"Verdana, Geneva, Arial, Helvetica, sans-serif", "baseFontSize":"10", "bgColor":"CC9900,FFFFFF", "canvasbgColor":"CC9900,FFFFFF" }, "data":[{"label":"NE","value":767}, {"label":"MA","value":527}, {"label":"MW","value":307}, {"label":"SE","value":146} ] } }, {"id":"TotalsOrders1", "linkedcharts":{"chart":{"caption":"Total Orders", "showLabels":"1", "showlegend":"1", "showBorder":"1", "baseFont":"Verdana, Geneva, Arial, Helvetica, sans-serif", "baseFontSize":"10", "bgColor":"CC9900,FFFFFF", "canvasbgColor":"CC9900,FFFFFF" }, "categories":[{"category":[{"label":"Total Web Orders"}, {"label":"Total Non-Web Orders"}, {"label":"Total Orders"} ] } ], "dataset":[{"seriesname":"NE", "data":[{"value":767}, {"value":64}, {"value":831} ] }, {"seriesname":"MA", "data":[{"value":527}, {"value":69}, {"value":596} ] }, {"seriesname":"MW", "data":[{"value":307}, {"value":34}, {"value":341} ] }, {"seriesname":"SE", "data":[{"value":146}, {"value":31}, {"value":177} ] } ] } ] } JSP Snippet: <c:set var="pathToChart" value="<%=chartPath%>"/> <c:set var="pos" value="0"/> <br/> <table border="0" cellpadding="1" cellspacing="1" width="800px" class="tblBox"> <c:forEach var="chart" items="<%=charts%>"> <c:set var="name" value="${chart.chartName}"/> <c:if test="${pos eq 0}"> <tr> </c:if> <td> <fc:render chartId="${chart.id}" swfFilename="${pathToChart}/${name}" debugMode="false" jsonData="${chart.json}" width="360" height="250"/> </td> <c:choose> <c:when test="${pos eq 2}"> <c:set var="pos" value="0"/> </tr> </c:when> <c:otherwise> <c:set var="pos" value="${pos + 1}"/> </c:otherwise> </c:choose> </c:forEach> <c:if test="${pos < 2}"> <c:forEach var="i" begin="${pos}" end="2" step="1"> <td> </td> </c:forEach> </tr> </c:if> </table> Based on your documentation configureLink will allow me to configure each child chart to user a certain chart swf file. Share this post Link to post Share on other sites