csvout Generates csv file output for selected tables on a page

  1. Documentation
  2. Change Log

This extension generates csv file output for selected tables on a page, multiple selection is allowed

Documentation

Requirements
  • Yii 1.0.5
Installation
  • Copy all the 'csv' catalogue under /protected/extensions

  • Register controller 'CsvController' in /protected/config/main.php:

[php]

 'controllerMap'=>array(
          'csv'=>array(
              'class'=>'application.extensions.csv.CsvController',
              'property1'=>'value1',
              'property2'=>'value2',
              ),
      ...........other controllers (if exist)
 ),

[php]

Usage
  • Add button(s) to your view page (several times, if needed - as many as you wish!):

[php]

    <?php $this->widget('application.extensions.csv.csvWidget', array(
                    'property1'=>'value1',
                    'property2'=>'value2')); 
     ?>

[php]

where possible properties with their default values are:

  • 'table' => '.dataGrid' string selector (understanding by jQuery $()-function) of the table(s) to be output, by default it's a 'table' with class='dataGrid' (selection result may be not single!)

  • 'csvFile' => '' string csv file name (if '', it will be 'data.csv' by default)

  • 'ignoredRow' => 'filterRow' string class name for the rows 'tr' which should be omitted in the csv output

  • 'ignoredCol' => 'actionCol' string class name for the cells 'td', 'th' to be omitted in the csv output

  • 'htmlOptions' => array() array htmlOptions array - standard for Yii

Change Log

July 5, 2009
  • Initial release.
6 1
4 followers
1 098 downloads
Yii Version: 1.1
License: BSD-2-Clause
Category: Others
Tags:
Developed by: kvl
Created on: Jul 5, 2009
Last updated: 8 years ago

Downloads

show all