how can use css in html ?
You don’t use CSS in html, you use it with HTML… And this question is too broad to answer. The best way (although not the only) is to create a CSS document and link it you your html page right in the HEAD area.
Examle: your css document is called mycss.css
then, your code in your html page would be
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" >
<title>Title of the Page</title>
<link rel="stylesheet" type="text/css" href="mycss.css">
</head>
Another Two ways are:
-
put the style tag in <head> like this:
<head>
<style>/Css Contents here/</style>
</head> -
put on elements as attributes like this:
<div style=“”></div>
<a style=“”></a>
–>This is not recommended.
This question is beyond basic, and has been answered. Thread closed.