only output html for classes if there are classes