CException

image directory unwritable

/var/www/gribam.ru/data/www/gribam.ru/konkurs2015/protected/extensions/iwi/vendors/image/Image.php(332)

320     {
321         // If no new image is defined, use the current image
322         empty($new_image) and $new_image = $this->image['file'];
323 
324         // Separate the directory and filename
325         $dir  = pathinfo($new_image, PATHINFO_DIRNAME);
326         $file = pathinfo($new_image, PATHINFO_BASENAME);
327 
328         // Normalize the path
329         $dir = str_replace('\\', '/', realpath($dir)).'/';
330 
331         if ( ! is_writable($dir))
332             throw new CException('image directory unwritable');
333 
334         if ($status = $this->driver->process($this->image, $this->actions, $dir, $file))
335         {
336             if ($chmod !== FALSE)
337             {
338                 // Set permissions
339                 chmod($new_image, $chmod);
340             }
341         }
342         
343         // Reset actions. Subsequent save() or render() will not apply previous actions.
344         if ($keep_actions === FALSE)

Stack Trace

#0
+
 /var/www/gribam.ru/data/www/gribam.ru/konkurs2015/protected/extensions/iwi/Iwi.php(64): Image->save("images/site/cache/8f/20/8f20aabc30cb33a51d8fad446d2136e0.jpg")
59     public function cache()
60     {
61         $path = $this->buildPath();
62         if ($path) {
63             if ($this->createOrNone() || !file_exists($path)) {
64                 $this->save($path);
65             }
66             return Yii::app()->createUrl($path);    
67         }
68         return false;
69     }
#1
+
 /var/www/gribam.ru/data/www/gribam.ru/konkurs2015/protected/views/photo/_view.php(5): Iwi->cache()
01 <?php
02 /* @var $this PhotoController */
03 /* @var $data Photo */
04 
05     $img_tag = '<img src="'.Yii::app()->iwi->load("$data->file")->resize(500,250,Image::AUTO)->cache().'" class="view-single-photo-preview">';
06 
07 ?>
08 <style>
09 div.view-single-photo div.blackbg, div.view-single-photo div.label {
10   height: 45px !important;
#10
+
 /var/www/gribam.ru/data/www/gribam.ru/konkurs2015/themes/gribam.ru/views/photo/index.php(169): CBaseController->widget("zii.widgets.CListView", array("dataProvider" => CActiveDataProvider, "itemView" => "_view", "id" => "photo-clistview", "ajaxUpdate" => false, ...))
164             'nextPageLabel'  => '&rsaquo;',
165             'lastPageLabel'  => '&raquo;',
166         ),
167         'template'=>"{summary}{items}{pager}",
168         'summaryText'=>"{start}&mdash;{end} из {count}.",        
169     )); ?>
170     </div>
171 </div>
2024-03-19 05:58:18 Apache/2.2.15 (CentOS) Yii Framework/1.1.14