FusionCharts API-Event: linkedItemClosed

Created using FusionCharts Suite XT - www.fusioncharts.com

by FusionCharts

HTML

<script src="https://static.fusioncharts.com/code/latest/fusioncharts.js"></script>
<script src="https://static.fusioncharts.com/code/latest/fusioncharts.charts.js"></script>
<!-- This sample shows the event parameters, and their values, when linkedItemClosed event is triggered-->
<div id="indicatorDiv">Event name: <strong> linkedItemClosed </strong> 
    
   <p>Triggered when a linked chart is closed to go back to its parent chart.</p>
   <p>All events, when triggered, will provide two parameters for the handler - <strong> eventObj </strong> (object containing information generic to all events) and <strong> dataObj </strong> (object containing information specific to an event).</p>
   <p>Click any of the columns to open a linked chart. Click the close button in te top-right corner of the child chart to trigger the event. Scroll down to the table rendered below the chart to view information contained in the dataObj object. To view information contained in the eventObj object, open the console.</p>
</div>
<div id="chart-container">FusionCharts will render here</div>
<div>
    <div>
        <div id="header">
            <div class="parameter-name">Parameter Name</div>
            <div class="parameter-value">Parameter Value</div>
        </div>
        <div id="attrs-table"></div>
    </div>
</div>

CSS

body {
    padding: 5px;
    margin: 0 auto;
}
strong {
  font-weight: bold;
}

#chart-container {
  margin: 10px 0;
}
#header {
    display: none;
}
#indicatorDiv {
    width: 500px;
    font-family:'Arial', 'Helvetica';
    font-size: 14px;
}
p {
    margin-top: 20px;
    margin-bottom: 20px;
}
#attrs-table {
    text-align: center;
    width: 500px;
}
.parameter-name, .parameter-value {
    width: 250px;
    font-weight: bold;
    text-align: center;
    float: left;
}
.title, .value {
    float:left;
    width: 230px;
    height: 20px;
    background: #fff;
    padding: 5px 10px;
}
.title {
    clear: left;
}
.title:nth-child(4n+1), .value:nth-child(4n+2) {
    background: rgb(0, 117, 194);
    color: #fff;
}
.value {
    word-wrap: break-word;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

JavaScript

FusionCharts.ready(function () {
    var salesChart = new FusionCharts({
        type: 'column2d',
        renderAt: 'chart-container',
        width: '500',
        height: '300',
        dataFormat: 'json',
        id: "myChartId",
        dataSource: {
            "chart": {
                "caption": "Top 3 Juice Flavors",
                    "subcaption": "Last year",
                    "xaxisname": "Flavor",
                    "yaxisname": "Amount (In USD)",
                    "numberprefix": "$",
                    "palettecolors": "#008ee4",
                    "canvasbgalpha": "0",
                    "canvasborderalpha": "0",
                    "useplotgradientcolor": "0",
                    "showplotborder": "0",
                    "placevaluesinside": "1",
                    "valuefontcolor": "#ffffff",
                    "captionpadding": "20",
                    "showaxislines": "1",
                    "axislinealpha": "20",
                    "divlinealpha": "20",
                    "showborder": "1",
                    "bgalpha": "0",
                    "animation": "0"
            },
                "data": [{
                "label": "Apple",
                    "value": "810000",
                    "link": "newchart-xml-apple"
            }, {
                "label": "Cranberry",
                    "value": "620000",
                    "link": "newchart-xml-cranberry"
            }, {
                "label": "Grapes",
                    "value": "350000",
                    "link": "newchart-xml-grapes"
            }],
                "linkeddata": [{
                "id": "apple",
                    "linkedchart": {
                    "chart": {
                        "caption": "Apple Juice - Quarterly Sales",
                            "subcaption": "Last year",
                            "numberprefix": "$",
                            "palettecolors": "#f8bd19,#e44a00,#008ee4,#33bdda,#6baa01,#583e78",
           ...