Sign in to follow this  

Getchartfromid Doesn't Work In Firefox And Chrome

Recommended Posts



I am frustrated with one bug, I have function call var chartObj = getChartFromId(id);. below code in FusionCharts.js file perfectly works IE but not in Firefox and Chrome. In case of Chrome and Firefox it returns null(chartObj is null), but in case of IE it is chart object and I can use setDataXML to change chart XML.



window.getChartFromId =


function (a) {


return f.core.items[a] instanceof f.core ? f.core.items[a].ref : f.swfobject.getObjectById(a)




function getObjectById(a) {

var r = null;

var o = getElementById(a);

if (o && o.nodeName == "OBJECT") {

if (typeof o.SetVariable != w) {

r = o

} else {

var n = o.getElementsByTagName(OBJECT)[0];

if (n) {

r = n




return r




Please help me.



Thanks & Regards,





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
Sign in to follow this