How to toggle chart visibility? in Miscellaneous Posted April 27, 2014 · Report reply Hi, while using the latest release of fusion charts XT, i ran into the following issue. On a page i am displaying 9 charts where i want to initially hide 6 of them. When the user clicks a 'show all' button, all charts should be shown. This does not work correctly with .show() or .slideToggle(). When clicking the button only 2 out of the 6 charts get shown and their size/position is not correct. Here the code i am using to control visibility: <button id="tbutton">Show All</button><script>$( "#tbutton" ).click(function() {$( "tr.hiddenrow" ).show();});</script>'; <tr><td><div id=chart1>Chart</div></td></tr> <tr><td><div id=chart2>Chart</div></td></tr> <tr><td><div id=chart3>Chart</div></td></tr> <tr class="hiddenrow" style="display: none;"><td><div id=chart4>Chart</div></td></tr> <tr class="hiddenrow" style="display: none;"><td><div id=chart5>Chart</div></td></tr> <tr class="hiddenrow" style="display: none;"><td><div id=chart6>Chart</div></td></tr> <tr class="hiddenrow" style="display: none;"><td><div id=chart7>Chart</div></td></tr> <tr class="hiddenrow" style="display: none;"><td><div id=chart8>Chart</div></td></tr> <tr class="hiddenrow" style="display: none;"><td><div id=chart9>Chart</div></td></tr> Regards, T
How to toggle chart visibility?
in Miscellaneous
Posted · Report reply
Hi,
while using the latest release of fusion charts XT, i ran into the following issue.
On a page i am displaying 9 charts where i want to initially hide 6 of them.
When the user clicks a 'show all' button, all charts should be shown.
This does not work correctly with .show() or .slideToggle().
When clicking the button only 2 out of the 6 charts get shown and their size/position is not correct.
Here the code i am using to control visibility:
<button id="tbutton">Show All</button>
<script>
$( "#tbutton" ).click(function() {
$( "tr.hiddenrow" ).show();
});
</script>';
<tr><td><div id=chart1>Chart</div></td></tr>
<tr><td><div id=chart2>Chart</div></td></tr>
<tr><td><div id=chart3>Chart</div></td></tr>
<tr class="hiddenrow" style="display: none;"><td><div id=chart4>Chart</div></td></tr>
<tr class="hiddenrow" style="display: none;"><td><div id=chart5>Chart</div></td></tr>
<tr class="hiddenrow" style="display: none;"><td><div id=chart6>Chart</div></td></tr>
<tr class="hiddenrow" style="display: none;"><td><div id=chart7>Chart</div></td></tr>
<tr class="hiddenrow" style="display: none;"><td><div id=chart8>Chart</div></td></tr>
<tr class="hiddenrow" style="display: none;"><td><div id=chart9>Chart</div></td></tr>
Regards,
T