Javascript examples for DOM HTML Element:Details
HTML5 Details/Summary Open at Top Close From Bottom
<html> <head></head> <body> <script> function closeDetails() {/*from w ww . j a v a2s . com*/ document.getElementById("details").removeAttribute("open"); window.location = "#details"; } </script> <details id="details"> <summary>Show Details</summary> <p>yadda yadda</p> <button onclick="closeDetails()">Close Details</button> </details> </body> </html>