From 14e3a355fb4c68cc6ab8d123e107e65b8511bd6f Mon Sep 17 00:00:00 2001 From: hukl Date: Sat, 14 Nov 2009 10:42:21 +0100 Subject: nodes :show now also includes a direct link to to the live version of the node. Additionally, I changed the default route to a named route so it is much easier to generate proper public paths and urls. --- app/views/nodes/show.html.erb | 4 ++-- config/routes.rb | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/nodes/show.html.erb b/app/views/nodes/show.html.erb index c077f6a..de4d8a2 100644 --- a/app/views/nodes/show.html.erb +++ b/app/views/nodes/show.html.erb @@ -9,8 +9,8 @@
- - + + diff --git a/config/routes.rb b/config/routes.rb index 9b5980b..c2590bd 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -33,6 +33,6 @@ ActionController::Routing::Routes.draw do |map| map.connect 'galleries/*page_path', :controller => 'content', :action => 'render_gallery' - map.connect '/*page_path', + map.content '/*page_path', :controller => 'content', :action => 'render_page' end -- cgit v1.3
Path<%= @page.public_link %>Public Link<%= link_to @page.public_link, content_url(@node.unique_path) %>
Author