CodeLab
Tutorials For Everyone
Run
<!Doctype HTML> <html> <head> <title>HTML Picture element</title> </head> <body> <h2>HTML picture element</h2> <p>Try resizing the browser screen to see the effects.</p> <picture> <source media="(max-width: 640px)" srcset="https://www.tutsinsider.com/wp-content/uploads/2019/09/picelement-640-300x225.jpg"> <source media="(max-width: 420px)" srcset="https://www.tutsinsider.com/wp-content/uploads/2019/09/picelement-420-300x225.jpg"> <img src="https://www.tutsinsider.com/wp-content/uploads/2019/09/picelement-800-300x225.jpg" alt="Flowers" style="width:auto;"> </picture> </body> </html>