fariborz khan
10-06-2013, 02:14 PM
i want create a widget and put a picture in it
i read forum an i see that i must create a template like this :
<div class="block">
<div class="cms_widget_header"> </div>
<div class="cms_widget_content widget_content">
<div style="text-align:center">
<a href="http://www.vbhispano.com/foros/sendmessage.php?subject=0" rel="nofollow">
<img alt="Publicidad Disponible" src="http://imagenes.chevereto.net/images/qnZaF.png" title="Publicidad Disponible">
</a>
</div>
</div>
and create a widget and put created template name to load that template for me
but i see that template use default vbulletin css.
Now:
i want push css of template to this widget that i can customize only this widget
in other hand i want push below item to my created template(i think i must use complete html code but i don't know what i must write it that contain style variable on it)
.widget_content {
background: none repeat-x scroll 0 0 #FFFFFF;
border: 1px solid #DADADA;
border-radius: 0 0 0 0;
color: #424242;
padding: 10px 6px;
}
that when i change this item change apply only to this widget.
what is the best way that i can do it easily i must say that i see blow links but i want easy way that i can do this.
[HOW TO - vB4] Rendering templates and registering variables - a short guide (https://vborg.vbsupport.ru/showthread.php?t=228078)
[HOW-TO vB4] Create a Widget using Plugins and Templates (https://vborg.vbsupport.ru/showthread.php?t=236245)
and see this beautiful guide from kh99
If you go to vbulletin CMS -> Widgets and click on "configure" next to your widget, at the bottom there's a Template Name field that probably says 'vbcms_widget_static_page'. You could copy the vbcms_widget_static_page template code to a new template, enter that new template name on the widget config page, then edit that template to look the way you want.
i read forum an i see that i must create a template like this :
<div class="block">
<div class="cms_widget_header"> </div>
<div class="cms_widget_content widget_content">
<div style="text-align:center">
<a href="http://www.vbhispano.com/foros/sendmessage.php?subject=0" rel="nofollow">
<img alt="Publicidad Disponible" src="http://imagenes.chevereto.net/images/qnZaF.png" title="Publicidad Disponible">
</a>
</div>
</div>
and create a widget and put created template name to load that template for me
but i see that template use default vbulletin css.
Now:
i want push css of template to this widget that i can customize only this widget
in other hand i want push below item to my created template(i think i must use complete html code but i don't know what i must write it that contain style variable on it)
.widget_content {
background: none repeat-x scroll 0 0 #FFFFFF;
border: 1px solid #DADADA;
border-radius: 0 0 0 0;
color: #424242;
padding: 10px 6px;
}
that when i change this item change apply only to this widget.
what is the best way that i can do it easily i must say that i see blow links but i want easy way that i can do this.
[HOW TO - vB4] Rendering templates and registering variables - a short guide (https://vborg.vbsupport.ru/showthread.php?t=228078)
[HOW-TO vB4] Create a Widget using Plugins and Templates (https://vborg.vbsupport.ru/showthread.php?t=236245)
and see this beautiful guide from kh99
If you go to vbulletin CMS -> Widgets and click on "configure" next to your widget, at the bottom there's a Template Name field that probably says 'vbcms_widget_static_page'. You could copy the vbcms_widget_static_page template code to a new template, enter that new template name on the widget config page, then edit that template to look the way you want.