Latest topics
» What's freelancing?
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyYesterday at 7:39 pm by Adminkunlex

» Java Game: Sportbikes Unlimited 240x320
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed Jun 03, 2020 6:57 pm by Adminkunlex

» Java Games: Kraze The Unlimited Racing 3d
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed Jun 03, 2020 6:56 pm by Adminkunlex

» Java Games: Extreme Moto Racing
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed Jun 03, 2020 6:55 pm by Adminkunlex

» Java Games: Stunt Car Racing 99 Tracks Touch
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed Jun 03, 2020 6:54 pm by Adminkunlex

» Java Games: 3D Bimmer Street Racing Touch
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed Jun 03, 2020 6:53 pm by Adminkunlex

» Christiano Ronaldo's 10 Most Iconic Career Moments
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed Jun 03, 2020 2:28 pm by Adminkunlex

» Young Boy nabbed for Raping 6-year-old girl in an Uncompleted building
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyMon Jun 01, 2020 3:38 pm by Litifyed

» Mr Gbafun x Oladips – Ko Necessary
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed May 27, 2020 9:25 am by Adminkunlex

» ZaddyMeek Ft. Mr Gbafun x Davolee – Nigga’s Doings
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyWed May 27, 2020 9:23 am by Adminkunlex

» Full Css Code For Waphosts.com Website
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyTue May 19, 2020 7:02 am by Adminkunlex

» Full Css Code For Waphosts.com Website
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyTue May 19, 2020 7:01 am by Adminkunlex

» Chelsea star Callum Hudson-Odoi has been arrested
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyMon May 18, 2020 8:52 pm by Litifyed

» MAKE $50 DAILY THROUGH DIGITAL TRADING
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyMon May 18, 2020 11:39 am by skynett

» MTN 1.5gb for ₦300
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyMon May 18, 2020 11:37 am by skynett

» Java Game: 4 Vengadores Hulk, Thor, Iron Man Capitn Amrica
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyMon May 18, 2020 7:48 am by Adminkunlex

» Java Game: Heroes of World War II: Flying Tigers
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyMon May 18, 2020 7:48 am by Adminkunlex

» Java Game: Call Of Duty: Modern Warfare: Force Recon
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptyMon May 18, 2020 7:47 am by Adminkunlex

» Are You Drinking Enough Water? 6 Signs You Need To Drink More Water
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptySun May 17, 2020 9:08 pm by Adminkunlex

» Advance Waphost File List Paging Code
Topics tagged under abc on 9jabaze - Entertainment | Webmaster | Browsing Tricks | Games/Apps Hub EmptySat May 16, 2020 6:46 pm by Adminkunlex



Current date/time is Fri Jun 05, 2020 1:54 am

Search found 1 match for abc

Difference between "div id" and "div class" in HTML

In addition to setting a style for a HTML element, CSS allows you to specify your own selectors called "id" and "class".
1.THE ID SELECTOR:
The id selector is used to specify a style for a
single, unique element.
The id selector uses the id attribute of the HTML
element, and is defined with”#".
The style rule below will be applied to the element
with id="abc":
#abc
{
Text-align: center;
Color: red;
}
2.THE CLASS SELECTOR:
The class selector is used to specify a style for a
group of elements. Unlike the id selector, the class
selector is most often used on several elements.
This allows you to set a particular style for many
HTML elements with the same class.
The class selector uses the HTML class attribute, and
is defined with a "."
In the example below, all HTML elements with
class="center" will be center-aligned:
.center
{
Text-align: center;
}
A class can be used several times, while an ID can
only be used once, so you should use classes for
items that you know you're going to use a lot. An
example would be if you wanted to give all the
paragraphs on your webpage the same styling, you
would use classes.Common id elements are things
like header, footer, sidebar. Common class elements
are things like highlight or external-link.


Source
by Adminkunlex
on Sun Jan 19, 2020 9:15 am
 
Search in: Blogging
Topic: Difference between "div id" and "div class" in HTML
Replies: 0
Views: 24

Back to top

Jump to: