technomark.in
Hot News

$(this) Selector And Children / Find In jQuery

Detect An Undefined Object Property In JavaScript

Rotate And Save Video Using VLC Media Player

Capitalize The First Letter Of String In JavaScript

Convert Any Files To Any Format Using VLC Media Player

Asp.Net AngularJS WCF IIS
DataBase Jquery Bikes Random
HomeContact Us Watch Our YouTube Channel ..........Blog Spot..........

Technomark.in

How To Logout From All Devices In Skype

Technomark.in

How To Embed Google Map In Your Code

Technomark.in

How To Install IIS (Internet Information Services) On Windows

Technomark.in

Enable Directory Browsing In IIS

View All


How To Define Multiple CSS Attributes In JQuery


Define Multiple CSS Attributes In JQuery

> Here we consider how to define multiple css attributes in jQuery.
> Lets start with one example here.
> Suppose we have a Div with particular height and width.

How To Define Multiple CSS Attributes In JQuery, Define Multiple CSS Attributes In JQuery, Define Multiple CSS Attributes, Multiple CSS Styles In JQuery, Multiple CSS Styles In JavaScript, jQuery add styles, jQuery add multiple styles, multiple style, Multiple CSS Attributes, jQuery, HTML, php

> We needs to add background color and border to this Div.
> In jQuery, we can use css function for adding style.
> For adding multiple styles, the best way is to define a class inside Style section.
> Add required styles inside this Class.
> Here we declare a class named newStyle inside Style section.
> We have added background color as red and Border of 4px.

.newStyle {
         background: red;
         border :4px solid black;
}



> Now use jQuery addClass for adding this class to the Div.

$(function () {
         $('#divID').addClass('newStyle');
});



> That's all, by this way we can add multiple style using jQuery.

Watch Video of this Content on Video Steaming


Post Your Comment

Name *


Email *


Comment * Please provide all three fields for posting Comment




Technomark.in

Book Train Tickets on IRCTC Quickly During Tatkal Period

Technomark.in

Before You Copy Any Image From Internet

View All

Privacy StatementDisclaimerSitemap