Module: Awestruct::Extensions::Tagger::TagLinker

Defined in:
lib/awestruct/extensions/tagger.rb

Instance Method Summary collapse

Instance Method Details



21
22
23
24
# File 'lib/awestruct/extensions/tagger.rb', line 21

def tag_links(delimiter = ', ', style_class = nil)
  class_attr = (style_class ? ' class="' + style_class + '"' : '')
  tags.map{|tag| %Q{<a#{class_attr} href="#{tag.primary_page.url}">#{tag}</a>}}.join(delimiter)
end