Toggle navigation
☰
HTML
CSS
Scripting
Database
<!DOCTYPE html> <html> <head> <title>Responsive Image Example</title> <style> .responsive-img { max-width: 100%; height: auto; border: 2px solid #ccc; } .container { width: 50%; margin: 0 auto; background-color: #f9f9f9; padding: 20px; resize: horizontal; overflow: auto; border: 1px dashed #999; } </style> </head> <body> <h2>Fluid Responsive Image</h2> <p>The container below is resizable in some browsers (drag the bottom-right corner). As the container gets smaller, the image scales down to fit.</p> <div class="container"> <img src="/pix/samples/18m.jpg" alt="Three cats" class="responsive-img"> </div> </body> </html>