Added support for custom html caption.

Added support for custom html caption to be inserted by the user.
Added support to specify custom item classes.