Template:HexCon

Purpose
This template takes a hexadecimal color code and converts it either to or from a condensed shortcut format. For colors in the format AABBCC, they can be condensed to ABC and still be properly recognized by HTML coding.

Usage
To use this template, type:

When a three digit hex code is entered, the template will convert it to the proper six digit hex code. If a six digit hex code is entered, the template will convert it to a three digit code if, and only if, it can be. To force all results to be six digits, add a second parameter with the text forced, not case sensitive.