Error In Yexcel Extinsion

Hi All

I need to read Excle file then insert it into my table So i used " yexcel" extension but I had this error after install




Property "CWebApplication.yexcel" is not defined.	



extension link :

http://www.yiiframew…xtension/yexcel

Can any one help ?

Thanks in advance

Up :)

Can you post your config? Also, the code where you call the extension may be helpful.

Thank you Keith for your comment :

main.php




	'components'=>array(

		'user'=>array(

			// enable cookie-based authentication

			'allowAutoLogin'=>true,

        	


		),

    	

    	/// Excel 

    	

    	'yexcel' => array(

	'class' => 'ext.yexcel.Yexcel'

),


//...../



Controller





	public function actionImpoertexcel()

	{

	   

   	

   	Yii::import('ext.yexcel.Yexcel');




$sheet_array = Yii::app()->yexcel->readActiveSheet('example.xls');

 

echo "<table>";

 

foreach( $sheet_array as $row ) {

	echo "<tr>";

	foreach( $row as $column )

    	echo "<td>$column</td>";

	echo "</tr>";

}

 

echo "</table>";

   	

		//$this->render('impoertexcel',array('data'=>$data));

	}



Error message





include(PHPExcel_Shared_ZipStreamWrapper.php): failed to open stream: No such file or directory



thanks in advance

See if this page helps you:

http://www.yiiframework.com/wiki/101/how-to-use-phpexcel-external-library-with-yii/

I’m surprised that the Yii extension doesn’t take care of this problem itself, but it seems like this is the issue. I’ve had to make these changes in my own projects to get PHPExcel to work.

Check Yexcel.php source code and see if you can’t do it manually with the help of the link Keith posted in order to fix autoload issues.