<!DOCTYPE html> <p>Click the button to add a red background color to all h2 elements.</p> <button onclick="w3.addStyle('h2','background-color','red')">Add Style</button> <div id="London" class="city"> <div id="Paris" class="city"> <div id="Tokyo" class="city"> </body> |
Click the button to add a red background color to all h2 elements. LondonLondon is the capital city of England. ParisParis is the capital of France. TokyoTokyo is the capital of Japan. |