EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: crosemffet on November 30, 2012, 04:03:44 AM



Title: trying to apply style to component
Post by: crosemffet on November 30, 2012, 04:03:44 AM
I'm trying to apply a style to validatebox component trough my whole application
I mean trought the whole application, each time a validatebox components uses, use the same predefined style.
I'm trying:

$.extend($.fn.validatebox.defaults,{
style: 'border:1px solid #A4BED4'
});

but it's not working.
what's wrong with my code?
thanks, in advance,


Title: Re: trying to apply style to component
Post by: stworthy on December 01, 2012, 12:08:38 AM
To apply a style to a validatebox component, define a style class and add it to the input markup of validatebox.
Code:
.myclass{
  border: 1px solid #A4BED4;
}
<input class="easyui-validatebox myclass" required>