Change Widget CSS

I call widget in view page like this.


And it gives HTML rendered like this.

<div id="yw2" class="portlet">

<div class="portlet-content">

...what my custom widget does...



Those two DIVs are generated by widget function.

The problem are the already defined CSS classes.

I want to modify these classes specific by each widget.

Do anyone have suggestions how to do this?

Thanks in advance.

Check out the

You have:




You will need to do:

$this->widget('MyCustomWidget', array('titleCssClass'=>'my-custom-class'));

Same for the other properties.

Great! Thanks.