Commit 65c719b1 authored by Jerome Mariette's avatar Jerome Mariette
Browse files

add Mattias de Hollander work

parent f97f3bc3
This diff is collapsed.
......@@ -67,6 +67,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
With selection :
{if $analyse_results|@count > 1 }
<button type="button" class="btn btn-small phylogeny-bar-view-btn multiple-selection-btn"><i class=" icon-signal"></i> Bar view</button>
<button type="button" class="btn btn-small phylogeny-stackedbar-view-btn multiple-selection-btn"><i class=" icon-signal"></i> Stacked Bar view</button>
<button type="button" class="btn btn-small phylogeny-krona-view-btn multiple-selection-btn"><i class=" icon-search"></i> Krona view</button>
<button type="button" class="btn btn-small venn-view-btn multiple5-selection-btn"><i class=" icon-search"></i> Venn view</button>
{else}
......
......@@ -331,6 +331,7 @@ class tx_nG6_pi1 extends tslib_pibase {
<script type="text/javascript" src="'.t3lib_extMgm::siteRelPath($this->extKey).'res/js/jquery.highcharts.js"></script>
<script type="text/javascript" src="'.t3lib_extMgm::siteRelPath($this->extKey).'res/js/jquery.highcharts.exporting.js"></script>
<script type="text/javascript" src="'.t3lib_extMgm::siteRelPath($this->extKey).'res/js/jquery.highcharts.more.js"></script>
<script type="text/javascript" src="'.t3lib_extMgm::siteRelPath($this->extKey).'res/js/jquery.highcharts.exportcsv.js"></script>
<script type="text/javascript" src="'.t3lib_extMgm::siteRelPath($this->extKey).'res/js/jsphylosvg-min.js"></script>
<script type="text/javascript" src="'.t3lib_extMgm::siteRelPath($this->extKey).'res/js/raphael-min.js"></script>
<script type="text/javascript" src="'.t3lib_extMgm::siteRelPath($this->extKey).'res/js/unitip.js"></script>
......
/**
* A small plugin for getting the CSV of a categorized chart
* http://jsfiddle.net/highcharts/cqjvD/
*/
(function (Highcharts) {
// Options
var itemDelimiter = ',', // use ';' for direct import to Excel
lineDelimiter = '\n';
var each = Highcharts.each;
Highcharts.Chart.prototype.getCSV = function () {
var xAxis = this.xAxis[0],
columns = [],
line,
csv = "",
row,
col;
if (xAxis.categories) {
columns.push(xAxis.categories);
columns[0].unshift("");
}
each (this.series, function (series) {
columns.push(series.yData);
columns[columns.length - 1].unshift(series.name);
});
// Transform the columns to CSV
for (row = 0; row < columns[0].length; row++) {
line = [];
for (col = 0; col < columns.length; col++) {
line.push(columns[col][row]);
}
csv += line.join(itemDelimiter) + lineDelimiter;
}
return csv;
};
}(Highcharts));
// Now we want to add "Download CSV" to the exporting menu. We post the CSV
// to a simple PHP script that returns it with a content-type header as a
// downloadable file.
// The source code for the PHP script can be viewed at
// https://raw.github.com/highslide-software/highcharts.com/master/studies/csv-export/csv.php
Highcharts.getOptions().exporting.buttons.contextButton.menuItems.push({
text: 'Download CSV',
onclick: function () {
Highcharts.post('http://www.highcharts.com/studies/csv-export/csv.php', {
csv: this.getCSV()
});
}
});
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment