Afficher un message
Vieux 30/05/2006, 14h40   #4
Marcus Bointon
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: [SMARTY] smarty and GNU gettext

On 30 May 2006, at 14:22, Vicente Werner wrote:

> You really don't want to use it, since the performance gains are
> negligible from a custon made library getting the stuff from a DB -
> I've done and made benchmarks and the results are similar with an
> edge going to custon made libraries when you're using high ammounts
> of translated terms- .


Personally I think gettext is a clunky way of working anyway! I'm
using a DB-based one at present - it's nice to have a separate web
interface for translators to use independent of web apps.

> For legibility reasons I implemented my system as block plugin:
> {translate}text{/translate} and added some localization functions
> to deal with numeric format etc..


I've done it as both block and function - I find functions are tidier
for small things like field titles. I've yet to come up with a nice
way of handling embedded variables like gettext does, especially with
numbered params. Any ideas on that?

Marcus
--
Marcus Bointon
Synchromedia Limited: Putting you in the picture
marcus@synchromedia.co.uk | http://www.synchromedia.co.uk
  Réponse avec citation
 
Page generated in 0,05201 seconds with 9 queries