Changes introduced in #2186 reverted.
Merge pull request #2191 from resurtm/revert-chtml-changes-in-2186

CHtml changes introduced in #2186 reverted.