Tryit Editor v2.3

Edit This Code:
<!DOCTYPE html> <html> <head> <style> h1:before { counter-increment: section; content: "Section " counter(section) ". "; } </style> </head> <body> <p>Click the "Try it" button to set the counter-reset property of the BODY element:</p> <button onclick="myFunction()">Try it</button> <h1>HTML Tutorials</h1> <h1>JavaScript Tutorials</h1> <h1>CSS Tutorials</h1> <script> function myFunction() { document.body.style.counterReset = "section"; } </script> </body> <!-- Mirrored from www.w3schools.com/cssref/tryit.asp?filename=trycss_js_counter-reset by HTTrack Website Copier/3.x [XR&CO'2014], Fri, 23 Jan 2015 07:51:44 GMT --> </html>
Result:
Try it Yourself - © w3schools.com