Issue With Cmultifileupload

Hey everyone

I have a little problem with CMultifileupload. Problem si with POSTing files to controller.

I have this very simple view (only for uploading files):


$form = $this->beginWidget(



				'id' => 'upload-form',

				'htmlOptions' => array('enctype'=>'multipart/form-data'),




<div class="row">

	<?php echo $form->labelEx($model, 'sourceCode');?>

	<?php echo //$form->fileField($model, 'sourceCode');?>



        $this->widget('CMultiFileUpload', array(


            'name' => 'sourceCode',

			'attribute'=> 'sourceCode',


            'accept' =>'zip',

            'duplicate' => 'Duplicate file!', 

            'denied' => 'Invalid file type',


         echo $form->error($model,'sourceCode'); 




<div class="row buttons">

		<?php echo CHtml::submitButton('Submit'); ?>




As you can see I have commented fileField because I am upgrading from 1 file to multiple file upload. But when I replaced it with CMultiFileUpload it didn’t even post to controller. I even tried as simple action controller as this:

public function actionUpload()


    $model = new UploadSolutionForm();



        echo 'Got it!';




But with fileField it echoes the message, but when replaced with CMultiFileUpload it doesn’t. So there seems to be somethink wrong with POST I think.

Just to clarify it work perfectly fine with fileField.

Here is my UploadSolutionForm just in case:

public $sourceCode;


    public function rules()


        return array(

            array('sourceCode', 'file', 'types'=>'zip', 'allowEmpty'=>false, 'wrongType'=>'Only .java, .cc and .zip files allowed'),



Anyone knows what’s wrong because this seems simple enough but for some reason it doesn’t work.

Help is very appreciated.


I too had the same problem. do u got any solution for this. :(