Sha256: 8306900d60d0fd4f7edc32c5ca1f6d8018d5f6cde837217aad7079751a434dce
Contents?: true
Size: 708 Bytes
Versions: 5
Compression:
Stored size: 708 Bytes
Contents
module Admin::ThemesHelper require('find') def fetch_stylesheets list = '' Find.find(this_blog.current_theme.path + "/stylesheets") do |path| if path =~ /css$/ list << content_tag(:p, link_to(File.basename(path), {:controller => 'themes', :action => 'editor', :type => 'stylesheet', :file => File.basename(path)})) end end list end def fetch_layouts list = '' Find.find(this_blog.current_theme.path + "/layouts") do |path| if path =~ /rhtml$|erb$/ list << content_tag(:p, link_to(File.basename(path), {:controller => 'themes', :action => 'editor', :type => 'layout', :file => File.basename(path)})) end end list end end
Version data entries
5 entries across 5 versions & 1 rubygems