Google Groups

Re: [jframe] Re: Bug in JView getName()


CirTap Apr 20, 2012 7:41 AM
Posted in group: Joomla! Framework Development
the regex only kicks in if you don't set the $name property:
if (empty($this->name)) { ... }


class ReviewsViewAdmin extends JView
{
  protected $name = 'reviews';

...
}


CirTap

>>
>> -> ReviewsViewAdmin
>>
>> Regular expression in the code:
>>
>> if (!preg_match('/View((view)*(.*(view)?.*))$/i', get_class($this), $r))
>>
>>
>> -> Result
>>
>> *sviewadmin* instead of Admin
>>
>> Is this something that can be fixed, or it's mandatory to avoid component
>> with the word "view" ?
>>
>>
>> Thomas
>>
>>
>>
>