doudu2404
2013-11-08 21:03
浏览 28
已采纳

PHP gettext变量大写/小写

I have gettext setup and working on Windows and IIS. I have translated US English to GB English. All is working well but I have a question which searching could not answer.

Do I need to have multiple translations for each variation of a word (uppercase, lowercase)?

Colour -> Color
colour -> color
COLOUR -> COLOR

etc.

Thanks

图片转代码服务由CSDN问答提供 功能建议

我已经设置了gettext并在Windows和IIS上工作。 我已将美国英语翻译成GB英语。 一切都运行良好,但我有一个搜索无法回答的问题。

我是否需要为单词的每个变体(大写,小写)设置多个翻译? \ n

 颜色 - > 颜色
colour  - >  color 
COLOUR  - >  COLOR 
   
 
 

等。

谢谢

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

1条回答 默认 最新

  • dqthn68688 2013-11-11 08:56
    已采纳

    Yes you do. GETTEXT is case-sensitive.

    Remember that different languages use different rules for capitalisation.

    English "fish" is German "Fisch" (nouns are always capitalised).

    Also remember that upper/lower case is a feature of latin scripts. Languages written in hebrew, arabic, etc. do not have capitals, so if you are using capitals to indicate emphasis, etc., you should find an alternative.

    点赞 打赏 评论

相关推荐 更多相似问题