Help:Wiki University Wikitext--Font Colors

From FamilySearch Wiki
Jump to navigation Jump to search




Other Coding Options

Additional Helps

Change font color[edit | edit source]

Changing colors.jpg

Sometimes you may want a different color for the font for emphasis. This is the attribute:

<p style="color:blue">...</p>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec sit amet iaculis metus. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Fusce elementum efficitur faucibus. Curabitur eleifend quis ligula ac ullamcorper. Curabitur eget suscipit turpis.

  • The number of "named" colors is 256.
  • However only 140 names are supported by ALL browsers. Here's the list found in

Html colors.PNG


You will also notice that alongside these "named" colors there is also a number value. This value is called a HEX number. You can use the HEX number instead of the name if you want. Sometimes the HEX code is shorter than the name of the color. Be sure to place the pound or hash tag # before the actual number. The computer will not process the HEX code without the # tag. The font color code using the HEX number would look like this:

<p style="color:#8A2BE2">...</p>

  • Click on the Shades column for more color selections. However, the shades do not have names so you will have to use the HEX codes.

Try these out[edit | edit source]

  • Change the lorem ipsum paragraph text to a color of your choice from w3schools.

Quick Quiz
  • You can use any common name for a color?
A. True
B. False
  • If the HEX number does not work in the code you may have:
A. Used a wrong number
B. Left off the # tag
C. All of the above
  • You have to use the header tags to color headers?
A. True
B. False