gludington

Detect Flash -- Replacement For Infosoftglobal.fusionchartsutil?

Recommended Posts

I need to detect and display specific messages for various charts in a dashboard-like page, and the built in detect flash version/auto redirect mechanism is not sufficient for that task. In past versions of FusionCharts, we could use infosoftglobal.FusionChartsUtil.getPlayerVersion() to determine the level of Flash player support in the current browser, but that mechanism only appears in the "legacy" FusionCharts files. What is the equivalent in FusionCharts 3.2?

Share this post


Link to post
Share on other sites
Guest Basundhara Ghosal

Hi,

 

As of now, FusionCharts 3.2 version does not support the same.

 

Could you please elaborate us the requirement, so that our development team could get a work-around for the same?

 

Awaiting your reply.

Share this post


Link to post
Share on other sites

Hi,

 

As of now, FusionCharts 3.2 version does not support the same.

 

Could you please elaborate us the requirement, so that our development team could get a work-around for the same?

 

Awaiting your reply.

 

Thank you for the response. In our specific case, we have fusioncharts portlets on a portal page. If Flash is not present, we would like to update the HTML of the portlet accordingly. Lacking any direct ability to check, I am working around it by instantiating the chart and listening for an internal event callback, as follows:

 

portlet.chart.addEventListener('internal.domelementcreated', function(evt, status) {
   if (status.success === false) {
       portlet.body.applyStyles('margin:40px');
       portlet.body.dom.update('<h3 class="radar_text">IPreportsV2 requires Flash Player version 8 or higher to run.  You may download it from <a href="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" target="_new">Adobe</a></h3>');
       evt.stopPropagation();
   }
});

 

But as an internal event, this seems like it is (or should be) unsupported, so I would prefer to have some official hook, preferably one that would not require me instantiating and loading charts in the first place, if possible.

Share this post


Link to post
Share on other sites

Thank you for the response. In our specific case, we have fusioncharts portlets on a portal page. If Flash is not present, we would like to update the HTML of the portlet accordingly. Lacking any direct ability to check, I am working around it by instantiating the chart and listening for an internal event callback, as follows:

 

portlet.chart.addEventListener('internal.domelementcreated', function(evt, status) {
   if (status.success === false) {
       portlet.body.applyStyles('margin:40px');
       portlet.body.dom.update('<h3 class="radar_text">IPreportsV2 requires Flash Player version 8 or higher to run.  You may download it from <a href="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" target="_new">Adobe</a></h3>');
       evt.stopPropagation();
   }
});

 

But as an internal event, this seems like it is (or should be) unsupported, so I would prefer to have some official hook, preferably one that would not require me instantiating and loading charts in the first place, if possible.

 

Fusioncharts demo pages are also affected. In the 3.2 distribution, look at:

 

(your host/path)Code/MyFirstChart/weekly-sales-multiple-charts.html

 

IE8 without flash installed throws an error rather than any sort of redirect or proper flashdetection, killing the page completely. This is a deployment showstopper.

Share this post


Link to post
Share on other sites

I understand your frustration as I've discussed this before in the past. See this thread here.

 

However, I wouldn't consider this a showstopper, as you say. It's an unfortunate bug (/feature request). There are MANY sniffers available to detect Flash. So we as developers have options. (I mention in the above-mentioned post that I use Dojo's built-in detection since we're a Dojo shop).

 

On the other hand, I would agree that proper Flash detection in an essentially Flash-based tool should be of the utmost priority.

Share this post


Link to post
Share on other sites

I understand your frustration as I've discussed this before in the past. See this thread here.

 

However, I wouldn't consider this a showstopper, as you say. It's an unfortunate bug (/feature request). There are MANY sniffers available to detect Flash. So we as developers have options. (I mention in the above-mentioned post that I use Dojo's built-in detection since we're a Dojo shop).

 

On the other hand, I would agree that proper Flash detection in an essentially Flash-based tool should be of the utmost priority.

 

You are correct; we have choices, and there are plenty of sniffers out there. Our problem was that we have to deliver fusioncharts graphs in portlet contexts where these libraries (or even fusioncharts.js itself) may not be in the page context when the portlet is first created, so using these methods was a bit tricky (and tedious). Admittedly, this is a narrow use case, and we fashioned a workaround similar to what you did, but, since we did, I suppose by definition I can no longer claim it as a showstopper :).

 

If fusioncharts were to expose methods (as it did in earlier versions) or events for fusionchart's internal swfobject/flash detection results, it would have been much, much better.

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