簡體   English   中英

I18n :: MissingInterpolationArgument with I18n.l

[英]I18n::MissingInterpolationArgument with I18n.l

運行此代碼時出現此錯誤I18n::MissingInterpolationArgument

<%= l Date.today, :format => :short %>

它以前曾經工作過,但現在在Ubuntu上使用Rails 2.3.5Ruby 1.8.7 (2010-06-23 patchlevel 299) [i686-linux]不再起作用了...

有人幫忙嗎?

Okey,為自己准備了一個快速修復程序。 不是我想要的方式,但是它有效

將此添加到en.yml文件

  date:                   
    formats:              
      default: "%d.%m.%Y" 
      short: "%b %e"      
      long: "%e. %B %Y"   

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM