Web.QHMIT
.com
Toggle navigation
☰
Home
HTML
CSS
Scripting
Database
Run
<!DOCTYPE html> <title>My Example</title> <style> #resizeMe { background: gold; width: 40px; height: 20px; margin: 7px; padding: 10px; border: 5px solid black; } </style> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script> <script> $( function() { $( "button" ).click( function() { $("#resizeMe").outerWidth( "150" ).outerHeight( "180" ); }); }); </script> <button>Resize the Box</button> <p>Includes padding and borders (but not margins).</p> <div id="resizeMe"> </div>
Preview