Skip to content

clarif/page_title_helper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PageTitleHelper

PageTitleHelper is a very very simple helper which provides two helper methods for setting page titles. It supports localized titles.

Example

In the view layout (e.g. application.html.erb for instance):

<head>
	...
	<%= site_title "MySite" %>
	...
</head>

In a view, the title helper takes a parameter which can be either a String or a Symbol. In case of a Symbol, its value is sent first to I18n.t to be translated. In all cases, the page title is added to the <title/> tag after the site name.

<div id="content">
	...
	<%= title "Welcome !" %>
	...
</div>

Installation

rails install git://github.com/clarif/page_title_helper.git

Copyright © 2011 Fabrice Clari, released under the MIT license

About

Very simple rails plugin to generate localized page titles.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published