Sign in to follow this  
Din Revah

Show Values Only When Mouseover? Msline2D Graph

Recommended Posts

I am trying to show values only when mouse over that point in the graph.

Is that possible?

Because I couldn't find any solution in your Documentation..

This is my code:



public function Generate_MSChart($category, $data, $chart, $width, $height, $str_params=false) 
{ 
   	$FC =  FusionCharts($chart, $width, $height);  
   	$FC->enablePrintManager();
   	$FC->setRenderer('javascript');

   	// Default str params
   	if ($str_params === false) {
   		$strParam="bgColor=F4F4F6,F4F4F6;showValues=0;showBorder=0;palette=2;numvdivlines=10;drawanchors=0;divlinealpha=30;alternatehgridalpha=20;setadaptiveymin=1;";
   	}

	// Set chart attributes 
       $FC->setChartParams($strParam);

       // Add category names
       foreach ($category as $ct) {
       	$FC->addCategory($ct);
       }

	// Add data
       foreach ($data as $dtk => $dte) {
       	$FC->addDataset($dtk, "");

       	foreach ($dte as $elm) {
       		$FC->addChartData($elm);
       	}
       }

       return $FC;
}

Edited by Din Revah

Share this post


Link to post
Share on other sites

Hi Din,

 

Glad yo know you were able to resolve the issue.

 

Setting "drawAnchors" to 0, the anchors are hidden and the tool tips for the data points will not be displayed and the links will not work either.

 

If you need to hide the anchors but still have tool tip and link, use: $strParam="anchorAlpha=0;"

 

 

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