HTML CSS examples for CSS Layout:Responsive Layout
Responsive image max height 100%
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> body, html { height:100%; margin:0; padding:0; } #content {<!-- w ww . j a va2 s .com--> height:100%; padding:51px; box-sizing:border-box; } #content img { max-height:100%; max-width:100%; } </style> </head> <body> <div id="content"> <img src="https://www.java2s.com/style/demo/Opera.png"> </div> <script type="text/javascript"> </script> </body> </html>