def tag_make(): from demisauce.model.tag import Tag alltags = Tag.by_key(site_id=site_id,tag_type=tag_type) tag_links = [] for tag in alltags: if tag in selected_tags: tag_links.append('''<a href="#" id="tag_%s" class="tagged">%s</a>''' % (tag.replace(':',''),tag)) else: tag_links.append("<a href=\"#\" id=\"tag_%s\">%s</a>" % (tag.replace(':',''),tag)) return ' '.join(tag_links)
def tag_keys(cls,site_id=0): return Tag.by_key(site_id,'help')