Weird,
It does work for me:
Example:
frontend/templates/layout.php:
<td align="center"><?php echo link_to(__('HOME'),'web/
index', array('class'=>'homeLink')); ?></td>
frontend/i18n/messages.es.xml:
<?xml version="1.0" ?>
<xliff version="1.0">
<file orginal="global" source-language="en_US" datatype="plaintext">
<body>
<trans-unit id="1">
<source>HOME</source>
<target>INICIO</target>
</trans-unit>
....
I guess this is case sensitive, try double check that.
As for extra attributes, you can add them in the options array, just
like I added a style class in the example above.
Good luck,
r.
El 24-08-2007, a las 7:26, Cacho escribió:
>
> Hi
>
> I want to use i18n with my application so I defined a messages.es.xml
> and a set i18n on in my app and then I can see how my template texts
> defined with __() are translated but likns defined with link_to, don
> ´t.
>
> I've tried to use something like link_to( __('Something'), 'mylink')
> but didn´t worked.
>
> How could I translate the first link_to parameter (the part that will
> be visible to the user) ?
>
> Also, I've noticed that links generated by link_to are not accesible
> as it doesn't make a title attribute. Is this true or am I forgeting
> something ?
>
> Thanks in advance
>
> C
>
>
> >
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---