This repository has been archived on 2020-05-27. You can view files and clone it, but cannot push or open issues/pull-requests.
2007-09-27 02:19:14 -04:00
|
|
|
module PagesHelper
|
2007-11-17 00:51:15 -05:00
|
|
|
def new_page_link
|
|
|
|
link_to 'New Page', new_page_path, { :title => 'Create a new page' }
|
|
|
|
end
|
|
|
|
|
2007-11-17 04:41:50 -05:00
|
|
|
def show_page_link(page, better_title = 'Show')
|
|
|
|
link_to better_title, page_path(page.title_for_url),
|
2007-11-17 00:51:15 -05:00
|
|
|
{ :title => page.title }
|
|
|
|
end
|
|
|
|
|
|
|
|
def edit_page_link(page)
|
|
|
|
link_to 'Edit Page', edit_page_path(page.title_for_url),
|
|
|
|
{ :title => "Edit #{page.title}" }
|
|
|
|
end
|
2007-09-27 02:19:14 -04:00
|
|
|
end
|