CSS is the language we use to style an HTML document. CSS stands for Cascading Style Sheets. CSS describes how HTML elements should be displayed.
CSS handles the look and feel part of a web page.
CSS is used to define styles for your web pages, including the design, layout and variations in display for different devices and screen sizes.
The style definitions are normally saved in external .css files.
The HTML style attribute is used to add styles to an element, such as color, font, size, and more.
Setting the style of an HTML element, can be done with the style attribute.
Syntax
<tagname style="property:value;">
example:
<h1 style="color:blue;"> Hello World </h1>
Syntax
<style> selector{ /* write here css properties */ } </style>
example:
<style>
h1{
background color: gray;
color:white;
}
</style>
Create a file and save with .css extension.
Write css code in this file.
Do not write <style> tag in .css file.
Syntax
fileName.css
Syntax
<link rel="stylesheet" href="path or url " >
example:
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" >
Comsysapp.com is an educational website. Students and software developers can learn programming language tutorials. Comsysapp is very useful for beginners and professional developers. Comsysapp provides tutorial in easy language. Comsysapp.com has focus on simplicity.
Comsysapp.com provides free tutorials like c, html, css, etc. All tutorials are free for beginner and professionals.
comsysapp.com is not responsible for any mistake. We are not responsible if information made available on our website is incomplete or invalid. But comsysapp.com always try for zero-zero mistake.
comsysapp.com does not collect any data from users. We use Google AdSense advertising on our website. We never ask personal or private information.
copyright © 2023