Is there a i18n/translation solution for Smarty?
Asked Answered
B

1

6

I'm developing a PHP-based application that requires internationalization (i18n) support.

I'm using Smarty 3 as a template solution (and TinyMVC as the framework), and although I've been using it for small projects before (back in the days of Smarty 2.x), I haven't known about any easy-to-use i18n plugins for it. Is there such plugin/extension for Smarty 3.x that'll do the job for me? I don't mind if the backend is a bit hard to setup, that's fine, all I need is a good way to implement it in templates.

I need to translate this app into multiple languages, so I need to find a way for Smarty to support it. Is there one? Thanks.

Berkeleianism answered 26/7, 2011 at 9:39 Comment(0)
R
3

You can use a gettext plugin with Smarty, such as the one posted on this thread which the poster developed for Smarty 3 and that he claims to have been using in production for over six months without issue.

Remsen answered 26/7, 2011 at 9:47 Comment(1)
Thanks. I'll give it a try right now and wait for a few more answers before I accept this, if you don't mind. That plugin lacks a little bit of documentation, though, but I think I'll figure it out. Now onto learning gettext! Haha.Berkeleianism

© 2022 - 2024 — McMap. All rights reserved.