Yiireport Suddenly Stopped Working

Hi there!

I’m experiencing some creepy issues using the YiiReport extension (http://www.yiiframework.com/extension/yiireport) to generate Excel files. I’ve coded a PHP file to generate an Excel from a database query and it worked perfectly; I’ve tested it on localhost and worked like charm, uploaded it on the online web and still worked as expected. However, some days ago I’ve tried again to export an Excel from the online web and it crashed! However, on the localhost version it still works as it used to, and the weird thing is that I didn’t even changed anything related to the YiiReport extension (I’ve uploaded new controllers and new extensions, but I haven’t touched anything related to the YiiReport)… The piece of code related to the YiiReport generating the Excel is the following one:

$r = new YiiReport(array('template'=> $template));



			'id' => 'ong',

			'data' => array(

				'name' => $nom











echo $r->render('excel2007', $filename);

The behaviour on Firefox shows a navigator page complaining that it is unable to find the page I’m trying to access; however, if I comment only the last line (the one that calls the ‘render’ function), the page is shown and no error is reported (though the Excel isn’t generated, of course)… Chrome doesn’t even show an error: just a blank page, and the PHP error log shows no errors nor warnings…

What can be happening? How is it it works on localhost but crashes weirdly when used online? Any can guess what can be happening? I’ve been dealing with it for days and I’m unable to find any clue…

Thanks in advance for your time and effort! :)

It looks like the directory permission issue. Did you check you can write temporary directory on the web server?

Hi Johnny, thanks for your reply!

Sorry, I’m a bit new on this and I’m not sure which directories or files I should check… I’ve checked permissions for the “protected/runtime” directory and all permissions are enabled but it doesn’t still work, so I guess maybe there’s some other directories or files I should check… Can you tell me which ones should have “writing” permissions enabled?

Thanks once more for your time! :)