0

How do I rename a ckEditorRow panel as highlighted below. I guess its taking the name from the passed in value (in this case 'subject').

enter image description here

I'm trying things like below but getting nowhere

$form->ckEditorRow($subject,'subject',array('options' => array('title'=>'new title')));

thanks

giles
  • 823
  • 3
  • 12
  • 25
  • What do you mean by rename? Id or label? What is value of `$subject`? –  Oct 07 '13 at 14:13
  • I've updated my question to be more accurate. I've just tried both your suggestions in the array with no effect. – giles Oct 07 '13 at 14:55

1 Answers1

0

To change label, ovverride attributeLabels in your $subject model.

Simply return array with field name as keys and value as label, ie:

public function attributeLabels()
{
    return array(
        'subject' => 'Custom Subject Label',
        ... more labels
    );
}
  • Thanks that's helpful, but I actially want to remove the whole label on the UI (in other words rename it ''). I obviously want the label to appear elsewhere so I can't try your suggestion. Is there no way I can rename the widget? – giles Oct 07 '13 at 15:16
  • Maybe try to set third param to `array('label' => false)`, default Yii widgets will hide label if set like that to false, but this is custom extension, so i'm not sure if it will work. –  Oct 07 '13 at 20:01