CodeLab
Tutorials For Everyone
Run
<!DOCTYPE html> <html> <head> <style> /* ==============(fieldset)============== */ fieldset { display: block; margin-left: 2px; margin-right: 2px; padding-top: 0.35em; padding-bottom: 0.625em; padding-left: 0.75em; padding-right: 0.75em; border: 2px groove (internal value); } /* ==============(fieldset)============== */ </style> </head> <body> <h1>CSS Default Value For <kbd>(fieldset)</kbd></h1> <div class="content"> <p>By default, "fieldset" element is displayed like this:</p> <fieldset> <legend>Biodata:</legend> Name: <input type="text"><br> Email: <input type="text"><br> Date of birth: <input type="text"> </fieldset> <h2>Default CSS Properties</h2> <pre class="default"> fieldset { display: block; margin-left: 2px; margin-right: 2px; padding-top: 0.35em; padding-bottom: 0.625em; padding-left: 0.75em; padding-right: 0.75em; border: 2px groove (internal value); } </pre> </div> <!--============= End =============--> <script> var h=document.querySelector("h1");h.style.padding="30px",h.style.background="#333",h.style.color="#fff",h.style.boxShadow="0 0 3px 0 #aaa",h.style.borderTopLeftRadius="5px",h.style.borderTopRightRadius="5px";var k=document.querySelectorAll("h1 kbd");k.forEach(function(e){e.style.color="#0f0"});var c=document.querySelector(".content");c.style.cssText="background:#f8f9fa;box-shadow:0 0 3px 0 #aaa;border-bottom-left-radius:5px;border-bottom-right-radius:5px;padding:20px 30px;margin-top:-22px";var p=document.querySelector(".default");p.style.cssText="background:#fefefe;box-shadow:inset 0 0 3px 0 #aaa;border-left:5px solid #333;padding:10px"; </script> </body> </html>