Jump to content

Export Feature on Stats


Recommended Posts

Hi! all. I need your help

 

I created custom stats what displayed table order.

I want to export that table.

 

How can i do that?

 

This is the sample export link

<a class="button export-csv" href="'.htmlentities($_SERVER['REQUEST_URI']).'&export=1"><span>'.$this->l('CSV Export').'</span></a>

And this is some export function

if (($id_export = (int)Tools::getValue('export')) == 1)
			$this->csvExport(array('layers' => 2, 'type' => 'line', 'option' => '1-'.(int)Tools::getValue('id_country')));
		elseif ($id_export == 2)
			 $this->csvExport(array('layers' => 0, 'type' => 'line', 'option' => '2-'.(int)Tools::getValue('id_country')));
		elseif ($id_export == 3)
			$this->csvExport(array('type' => 'pie', 'option' => '3-'.(int)Tools::getValue('id_country')));

I dont know what the meaning of the script

$this->csvExport(array('layers' => 2, 'type' => 'line', 'option' => '1-'.(int)Tools::getValue('id_country')));

Anybody please help me!

post-711125-0-66444200-1388986442_thumb.png

Link to comment
Share on other sites

×
×
  • Create New...