aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_view/helpers
diff options
context:
space:
mode:
authorSven Fuchs <svenfuchs@artweb-design.de>2008-08-25 11:06:18 +0200
committerSven Fuchs <svenfuchs@artweb-design.de>2008-08-25 11:06:18 +0200
commit90a9637d41016c0d230ba36657e83a4f8d54cc46 (patch)
treefd06c77e3259e59debc94ccf5a9383cc5059cbec /actionpack/lib/action_view/helpers
parent23fb26a0dcbd46d36bdbc2caa267aa3192f77a24 (diff)
downloadrails-90a9637d41016c0d230ba36657e83a4f8d54cc46.tar.gz
rails-90a9637d41016c0d230ba36657e83a4f8d54cc46.tar.bz2
rails-90a9637d41016c0d230ba36657e83a4f8d54cc46.zip
I18n: add aliases #t and #l to TranslationHelper#translate and #localize
Diffstat (limited to 'actionpack/lib/action_view/helpers')
-rw-r--r--actionpack/lib/action_view/helpers/translation_helper.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/actionpack/lib/action_view/helpers/translation_helper.rb b/actionpack/lib/action_view/helpers/translation_helper.rb
index 60ac5c8790..de4c1d7689 100644
--- a/actionpack/lib/action_view/helpers/translation_helper.rb
+++ b/actionpack/lib/action_view/helpers/translation_helper.rb
@@ -11,10 +11,12 @@ module ActionView
keys = I18n.send :normalize_translation_keys, e.locale, e.key, e.options[:scope]
content_tag('span', keys.join(', '), :class => 'translation_missing')
end
+ alias :t :translate
def localize(*args)
I18n.localize *args
end
+ alias :l :localize
end
end
end \ No newline at end of file