Sign in to follow this  
OMMPAVAN

Java Script Execution

Recommended Posts

The same exeample is not working in my system . javascript is enabled and when i click on link that function is not calling .Both two files are in same folder

 

 

<html>

<head>

<title>JavaScript Link Example</title>

<script language="JavaScript" src="../FusionCharts/FusionCharts.js"></script>

<script LANGUAGE="JavaScript"><!--

function myJS(myVar){

window.alert(myVar);

}

// --></SCRIPT>

</head>

<body bgcolor="#ffffff">

<div id="chartdiv" align="center">The chart will appear within this DIV. This text will be replaced by the chart.</div>

<script type="text/javascript"><!--

var myChart = new FusionCharts("Column2D.swf",

"myChartId", "500", "300", "1",

"1");

myChart.setXMLUrl("data.xml");

myChart.render("chartdiv");

// --></script>

</body>

</html>

 

--------------------Data.xml--------------------------

 

<chart caption='ABC Bank Branches' subCaption='(In

Asian Countries)' yaxislabel='Branches' xaxislabel='Country'>

<set label='Hong Kong' value='235' link='j-myJS-Hong Kong, 235'/>

<set label='Japan' value='123' link='j-myJS-Japan, 123'/>

<set label='Singapore' value='129' link='j-myJS-Singapore, 129'/>

<set label='Malaysia' value='121' link='j-myJS-Malaysia, 121'/>

<set label='Taiwan' value='110' link='j-myJS-Taiwan, 110'/>

<set label='China' value='90' link='j-myJS-China, 90'/>

<set label='S. Korea' value='86' link='j-myJS-S.Korea, 86'/>

</chart>

Share this post


Link to post
Share on other sites
Guest Sumedh

The same exeample is not working in my system . javascript is enabled and when i click on link that function is not calling .Both two files are in same folder

 

 

<html>

<head>

<title>JavaScript Link Example</title>

<script language="JavaScript" src="../FusionCharts/FusionCharts.js"></script>

<script LANGUAGE="JavaScript"><!--

function myJS(myVar){

window.alert(myVar);

}

// --></SCRIPT>

</head>

<body bgcolor="#ffffff">

<div id="chartdiv" align="center">The chart will appear within this DIV. This text will be replaced by the chart.</div>

<script type="text/javascript"><!--

var myChart = new FusionCharts("Column2D.swf",

"myChartId", "500", "300", "1",

"1");

myChart.setXMLUrl("data.xml");

myChart.render("chartdiv");

// --></script>

</body>

</html>

 

--------------------Data.xml--------------------------

 

<chart caption='ABC Bank Branches' subCaption='(In

Asian Countries)' yaxislabel='Branches' xaxislabel='Country'>

<set label='Hong Kong' value='235' link='j-myJS-Hong Kong, 235'/>

<set label='Japan' value='123' link='j-myJS-Japan, 123'/>

<set label='Singapore' value='129' link='j-myJS-Singapore, 129'/>

<set label='Malaysia' value='121' link='j-myJS-Malaysia, 121'/>

<set label='Taiwan' value='110' link='j-myJS-Taiwan, 110'/>

<set label='China' value='90' link='j-myJS-China, 90'/>

<set label='S. Korea' value='86' link='j-myJS-S.Korea, 86'/>

</chart>

 

Hi,

 

Did you get any error? if yes then can you share error details of the same?

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