<!DOCTYPE html> <html> <head> <title>Page Title</title> </head> <body> <h2> Text color by ColorName </h2> <h1 style="color:Tomato;">This is a heading</h1> <p style="color:DodgerBlue;">This is a paragraph.</p> <p style="color:MediumSeaGreen;">This is another paragraph.</p> <h2> Text color by ColorCode </h2> <h1 style="color:#ff0000;">This is a heading</h1> <p style="color:#0000ff;">This is a paragraph.</p> <p style="color:#00ff00;">This is another paragraph.</p> <h2> Text color by RGB Value </h2> <h1 style="color:rgb(255, 0, 0);">This is a heading</h1> <p style="color:rgb(0, 0, 255);">This is a paragraph.</p> <p style="color:rgb(0, 255, 0);">This is another paragraph.</p> <h2> Text color by RGBA Value </h2> <h1 style="color:rgba(255, 0, 0, 1);">This is a heading</h1> <p style="color:rgba(0, 0, 255, 1);">This is a paragraph.</p> <p style="color:rgba(0, 255, 0, 1);">This is another paragraph.</p> <h2> Text color by HSL Value </h2> <h1 style="color:hsl(0, 100%, 50%);">This is a heading</h1> <p style="color:hsl(240, 100%, 50%);">This is a paragraph.</p> <p style="color:hsl(120, 100%, 50%);">This is another paragraph.</p> </body> </html>
Run