Just add locations synchronization when translate content.
In i18sync.module on line 400 :

if (module_exists('location')) {
    $options['locations'] = t('Location settings');
}

that works perfectly.

CommentFileSizeAuthor
#3 426294.patch481 bytesdouggreen

Comments

summit’s picture

Subscribing, does this module translate location fields like country also?
greetings,
Martijn

zedzed’s picture

Not translate location, just synchronize.
If you add this code, a new option is in content management. When you edit content type, new option "Location settings" is in Workflow settings >Synchronize translations.
If you check this, locations informations are synchronized between translated node.
In fact, just copy $node->locations information.

i18sync already synchronize data from other module (i18nsync.module line 393) :

 if (module_exists('comment')) {
    $options['comment'] = t('Comment settings');
  }
  if (module_exists('upload')) {
    $options['files'] = t('File attachments');
  }

always, sorry for my english ... i hope you understand me...

Seb

douggreen’s picture

Status: Active » Needs review
StatusFileSize
new481 bytes

This works great. Attached is the 5.x patch file. I'd mark it RTBC except I'm attaching a 5.x patch and the issue version is 6.x. Someone should attach a patch for 6.x and mark the status RTBC.

jose reyero’s picture

Version: 6.x-1.0 » 5.x-3.x-dev
Status: Needs review » Patch (to be ported)

Added the location field to 6.x, so re-tagging this one for 5.x

Thanks.

About the 5.x version, that one is on maintenance mode, no new features planned (Unless someone wants to take care of that branch and wants to test and commit these small patches there..)

However, I'd strongly encourage everybody to upgrade to 6.x

thommyboy’s picture

@Jose Reyero

i use the newest 6.x release and the code you mentioned is included in the i18sync.module
but I can't see any setting for location in the "synchronise translations" sections for the contenttype
and lon/lat are not synchronised into translations?

any idea?
regards tom

jose reyero’s picture

Version: 5.x-3.x-dev » 6.x-1.x-dev
Status: Patch (to be ported) » Fixed

I think I've just fixed the issue

Not for 5.x anymore, no new features for that version.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

juves’s picture

Version: 6.x-1.x-dev » 7.x-1.0-beta6
Status: Closed (fixed) » Active

Hello

Can you please add this feature to 7 branch?

jose reyero’s picture

Project: Internationalization » Location
Version: 7.x-1.0-beta6 » 7.x-4.x-dev

We are not adding any more contrib module related stuff into i18n. We are providing a hook instead for modules to define their own fields.

Now every module can implement hook_i18n_sync_options(), that can be on its own file 'location.i18n.inc'. Still undocumented but see i18n_sync.modules.inc

So moving to Location module.

juves’s picture

Status: Active » Closed (won't fix)

Ok, it work's with Location_CCK, there is a similar issue with "won't fix"

velpan’s picture

append this at the end of i18n_sync.modules.inc


/**
 * Location module. Implements hook_i18n_sync_options().
 */
function location_i18n_sync_options($entity_type, $bundle_name) {
  if ($entity_type == 'node') {
    $fields['location'] = array('title' =>  t('Location settings'));
    $fields['locations'] = array('title' =>  t('Locations'));
    return $fields;
  }
}


tostinni’s picture

Thanks for the snippet, however, you should better put it inside a custom module instead of modifying i18n_sync.

drupalina’s picture

Is there a solution for this in 7.x ???
I want the City names to be translatable.
I've created a module using code in #11, but nothing changes. The city names are still untranslatable.

morettolss’s picture

Issue summary: View changes

Just try patch #11, it works. Remember to clean cache.