示例#1
0
 * @category   PHPExcel
 * @package    PHPExcel_Reader
 * @copyright  Copyright (c) 2006 - 2010 PHPExcel (http://www.codeplex.com/PHPExcel)
 * @license    http://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt	LGPL
 * @version    1.7.3, 2010-05-17
 */


/** PHPExcel root directory */
if (!defined('PHPEXCEL_ROOT')) {
	/**
	 * @ignore
	 */
	define('PHPEXCEL_ROOT', dirname(__FILE__) . '/../../');
	require(PHPEXCEL_ROOT . 'PHPExcel/Autoloader.php');
	PHPExcel_Autoloader::Register();
	PHPExcel_Shared_ZipStreamWrapper::register();
	// check mbstring.func_overload
	if (ini_get('mbstring.func_overload') & 2) {
		throw new Exception('Multibyte function overloading in PHP must be disabled for string functions (2).');
	}
}

/**
 * PHPExcel_Reader_Excel2007
 *
 * @category   PHPExcel
 * @package    PHPExcel_Reader
 * @copyright  Copyright (c) 2006 - 2010 PHPExcel (http://www.codeplex.com/PHPExcel)
 */
class PHPExcel_Reader_Excel2007 implements PHPExcel_Reader_IReader
示例#2
0
 /**
  * Create a new PHPExcel with one Worksheet
  */
 public function __construct()
 {
     PHPExcel_Autoloader::Register();
     // Initialise worksheet collection and add one worksheet
     $this->_workSheetCollection = array();
     $this->_workSheetCollection[] = new PHPExcel_Worksheet($this);
     $this->_activeSheetIndex = 0;
     // Create document properties
     $this->_properties = new PHPExcel_DocumentProperties();
     // Create document security
     $this->_security = new PHPExcel_DocumentSecurity();
     // Set named ranges
     $this->_namedRanges = array();
     // Create the cellXf supervisor
     $this->_cellXfSupervisor = new PHPExcel_Style(true);
     $this->_cellXfSupervisor->bindParent($this);
     // Create the default style
     $this->addCellXf(new PHPExcel_Style());
     $this->addCellStyleXf(new PHPExcel_Style());
 }