Fix invalid HTML attribute value.
Use multibyte mb_strlen().

+ Also change HTML attributes to lower case.
Add missing `value` attribute.
Support empty list value.

+ This works around an issue with empty strings in the configuration,
  by allowing a list value consisting of only whitespace (e.g. " ") to
  be considered equal to an empty string.  This allows a list-type
  element to be "optional" by providing an empty value.