Closed (fixed)
Project:
ImageField
Version:
6.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
22 Apr 2009 at 06:02 UTC
Updated:
8 Dec 2010 at 15:36 UTC
Hi,
It seems that imagefield does not support i18n translations;
I would like to be able to translate texts that we can associate with imagefield (title, alt, description).
Could you add this feature please (some t() in scripts) ?
Thank you
Comments
Comment #1
quicksketchImageField should completely support translations when used with the translation.module (i18n module helps too). Translate the desired node, then update the alt and title text in the new translation. Technically speaking, wrapping t() around dynamic strings is very frowned upon, since there's no way to clean up those strings if the node were to be updated or deleted, permanently cluttering the database with strings that no longer are needed.
Comment #2
chipway commentedOk,
Thank you.
Your method seems better. May be i forgot soemthing.
I tried your way and it runs.
Thank you
Comment #3
Farreres commentedJust a quick note on this. ALT texts are properly internationalized when a new translation is created.
BUT
Default alt texts are not. There is only one default alt text, when there should be a different default alt text per language.
Can it be corrected? Or is there something I am missing?
Comment #4
gaele commentedI stumbled upon this. Reopened because of #3.
Comment #5
LarsKramer commentedI want the images to be syncronized within a set of translated nodes, but still being able to put language specific ALT and title texts. At the moment, it seems this is not possible. Is it a bug, or is it meant to be so?
Comment #6
quicksketchThat's right, because there's no possible option in i18n for "Sync part of a field but not others". I'd suggest just disabling syncing if you need different ALT and Title tags. Either that or disable ALT and Title within the ImageField and add them as separate fields. Then use theming to put them all back together again.
Comment #7
LarsKramer commentedOk, thanks for your quick reply. I'll have a look and see what works best.
Do you think the option to enable syncronization only for the image and not its text attributes could be facilitated by i18n? I might post a feature request in its issue queue about that.
UPDATE: there is a related issue here in i18n:
Image Title and Alt fields with Taxonomy i18n-term do not switch language
Comment #8
LarsKramer commentedOk, I have been experimenting some more now: When I disable syncronization, ALT and TITLE texts can be translated differently, and it is not necessary to re-upload the image when adding a new translation, only if you as translator by accident removes the image. Of course, the disadvantage is that if you later change or add images, you would have to repeat it for all translations.
On the other hand, I find the Imagefield tokens module quite useful. It seems that with this module enabled you can have different tokens, and at the same time have the photos synchronized. What I did was to disable custom translation and put the [title] token as default ALT and TITLE texts. Not a perfect solution, but it works.
Comment #9
quicksketchFor people using 3.7, you probably were getting bit by this bug: #749926: Imagefield title and alt field are reset after re-editing source node. The 3.8 version of ImageField and FileField should work properly with i18n again (with synchronization disabled). I'm closing this issue as translation has been possible for some time through i18n.