added tpl_classes() function to keep latest stable working