Javscript: HTML demo thay đổi background
RUN
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Javascript Example</title> </head> <body> <h2>Thay đổi CSS cho thẻ HTML</h2> <div id="content" style="padding: 20px; background: #ddd; color: white; margin: 40px 0px;"> CHÀO MỪNG BẠN ĐẾN VỚI FREETUTS.NET </div> <input type="button" id="btn1" value="Đổi Backgroud màu đỏ"/> <input type="button" id="btn2" value="Đổi Backgroud màu xanh"/> </body> </html>
PHÓNG TO