سؤال

When using <tr:chart> component from Trinidad lib there is problem using it in Explorer since it does not have built in support for SVG viewer.

Trinidad has hard coded url in case of error which open adobe page of SVG viewer. The problem is that it link is not updated since there is no SVG installation in adobe.

We need to supply different link. how can we override this URL?

Is there any better solution ?

Adobe have decided to discontinue support for the SVG viewer on January 1, 2009.

هل كانت مفيدة؟

المحلول

Ever considered using Highcharts to generate graphs in your Trinidad project? We do and it works like a charm! It does not use SVG on older versions of Internet Explorer; see Highcharts compatibility documentation. Also, Highcharts has way more possibilities to generate graphs and add interactivity then <tr:chart>. Actually, <tr:chart> is kind of limited in its possibilities.

The downside is that you don't have a JSF component to work with. Creating a static graph will be easy, but you might want to write a few lines of code to pass your data to the Highcharts Javascript to get things a bit more interesting. Trinidad's ExtendedRenderKitService comes in handy there:

ExtendedRenderKitService service = 
  Service.getRenderKitService(facesContext, ExtendedRenderKitService.class);
service.addScript(facesContext, "alert('foo');");
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top