there is my class Using $this when not in object context.
<?php
class Adverts extends CActiveRecord
{
public function getMainImage($id=0, $t=0){
return $this->images($id, 'main-image', $t);
}
public static function mainPic($id, $t=0){
$thumb = $t ? 'thumbs/':'';
return self::urlDir($id).$this->getMainImage($id,$t);<---error line
}
.......
Why i can't call simple method in static method???