top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration Why to Join

Facebook Login
Site Registration
Print Preview

What is an ID selector in CSS and how is it used?

0 votes
7 views
posted 6 days ago by Deepa
Share this question
Facebook Share Button Twitter Share Button Google+ Share Button LinkedIn Share Button Multiple Social Share Button

1 Answer

0 votes

ID selectors are used to identify and apply styling to a single specific HTML element. ID selectors are defined within the HTML page by inserting an ID in the HTML element.
Example:

<h1 id="id-selector">Lorem Ipsum</h1>

ID selectors are defined within the CSS page by calling a ‘#’ followed by the name of the ID.
Example:

#id-selector {
font-family: Arial;
font-size: 20;
}

ID selectors are unique and can only be applied to a single element.

answer 4 days ago by Sanam

Your answer

Preview

Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.

Useful Links with Similar Problem
Contact Us
+91 9880187415
sales@queryhome.net
support@queryhome.net
#470/147, 3rd Floor, 5th Main,
HSR Layout Sector 7,
Bangalore - 560102,
Karnataka INDIA.
QUERY HOME
...