sedDataURL on hidden charts

Recommended Posts





We are using FusionCharts V3 in our application. I am facing an issue with the setDataURL JS method.




We are displaying charts in two tabs in our web application. In tab 1, we have 4 charts and in tab 2, we have 3 charts. Along with the charts we have a filter for chart duration in each tab. There are 2 problems that we are facing




1) On page load the tab 2 is not displayed; so if i call the setDataURL() method on the 3 charts in tab 2 (which are not visibile - the whole tab has a display:none) I get a JS error ( __flash__addCallback is not defined ). The same is observed when 2 charts are not visible in the viewport and you need to scroll to see it




2) On page load I set the chart url as abc.php?duration=1hour. Once the page loads I change the duration filter from 1 hour to 1 day - based on this I set the url via setDataURL() to abc.php?duration=1day. Now i navigate to tab 2 (so tab1 is not visible) and then when I navigate back to tab 1 the charts are re-rendered with the initial url (abc.php?duration=1hour) and not to the latest URL that I have set. How do i overcome this issue? Am I using setDataURL() correctly or is this a bug?







Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now