diff --git a/config.rb b/config.rb index a0633d7..676b169 100644 --- a/config.rb +++ b/config.rb @@ -41,6 +41,25 @@ # @which_fake_page = "Rendering a fake page with a variable" # end + +page "/source/new.html", :layout => "template" + + +### +#Sitemaps +### + + +ready do + sitemap.pages.group_by {|p| p.data["source"] }.each do |source, pages| + page "/source/#{source}.html", :proxy => "new.html" do + @source = source + @pages = pages + end + end +end + + ### # Helpers ### @@ -82,4 +101,4 @@ # Or use a different image path # set :http_path, "/Content/images/" -end \ No newline at end of file +end diff --git a/source/layouts/template.html.erb b/source/layouts/template.html.erb new file mode 100644 index 0000000..893c922 --- /dev/null +++ b/source/layouts/template.html.erb @@ -0,0 +1,14 @@ + + +
+This is a sample page which uses a custom template
diff --git a/source/partials/_footer.html.erb b/source/partials/_footer.html.erb new file mode 100644 index 0000000..cf5c074 --- /dev/null +++ b/source/partials/_footer.html.erb @@ -0,0 +1 @@ +