counter html

Solutions on MaxInterview for counter html by the best coders in the world

showing results for - "counter html"
Cristina
19 Jan 2019
1<!DOCTYPE html>
2<html>
3<head>
4<style>
5body {
6  counter-reset: section;
7}
8
9h2::before {
10  counter-increment: section;
11  content: "Section " counter(section) ": ";
12}
13</style>
14</head>
15<body>
16
17<h1>Using CSS Counters:</h1>
18<h2>HTML Tutorial</h2>
19<h2>CSS Tutorial</h2>
20<h2>JavaScript Tutorial</h2>
21
22</body>
23</html>
24