"Sum of 2014-01-01"
Is there a way to modify the header to just say "cost", "amt_due", or "leads”?
(The Add Image control in the forum editor does not work.)
cost amt_due leads | franchise date
--------------------------------------------------------------
catetory type campaign | franchise1
| date1 date2 date2
| Sum of date1 | Sum of date1 | Sum of date1 <---- I'd like these to say "cost Sum of date1" "amt_due Sum..." "leads Sum..."
CODE minus top part...
$pivot = new KoolPivotTable("pivot");
$pivot->scriptFolder = $KoolControlsFolder ."/KoolPivotTable";
$pivot->styleFolder = "office2007";
$pivot->DataSource = $ds;
//Turn on ajax features.
$pivot->AjaxEnabled = true;
//Set the Width of pivot and use horizontal scrolling
//$pivot->Width = "1200px";
$pivot->HorizontalScrolling = true;
//Set the Height of pivot and use Vertical Scrolling
//$pivot->Height = "1000px";
$pivot->VerticalScrolling = true;
//Allow filtering
$pivot->AllowFiltering = true;
//Allow sorting
$pivot->AllowSorting = true;
//Allow reordering
$pivot->AllowReorder = true;
$pivot->Pager = new PivotPrevNextAndNumericPager();
$pivot->Pager->PageSize = 30;
$pivot->AllowCaching = true;
$field = new PivotSumField("cost");
$field->FormatString = "\${n}";
$pivot->AddDataField($field);
$field = new PivotSumField("amt_due");
$field->FormatString = "\${n}";
$pivot->AddDataField($field);
$field = new PivotSumField("leads");
$pivot->AddDataField($field);
$field = new PivotField("category");
$field->Expand = true;
$pivot->AddRowField($field);
$field = new PivotField("type");
$field->Expand = true;
$pivot->AddRowField($field);
$field = new PivotField("campaign");
$pivot->AddRowField($field);
$field = new PivotField("franchise");
$field->Expand = true;
$pivot->AddColumnField($field);
$field = new PivotField("date");
$pivot->AddColumnField($field);
$pivot->Process();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>KoolPivotTable</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
</head>
<body>
<form id="form1" method="post">
<?php echo $koolajax->Render();?>
<div style="padding-top:10px;">
<?php echo $pivot->Render();?>
</div>
</form>
</body>
</html>