HTML Editor
<!DOCTYPE html> <html lang="en-US"> <head> <style> div{ width: 300px; padding: 20px 10px; margin-bottom: 10px; text-align: center; border: 1px solid #8c8c8c; } </style> </head> <body> <h1>CSS box-shadow property</h1> <div> My Container </div> <button onclick="myFunction()">Click Me</button> <script> var x = document.getElementsByTagName("div")[0]; function myFunction(){ x.style.boxShadow = "0 8px 16px 0 rgba(0,0,0,0.4)"; } </script> <p><strong>Note</strong>: Click on the button to apply css 'box-shadow' property.</p> </body> </html>
OUTPUT
×

Save as Private