Outils pour utilisateurs

Outils du site


Panneau latéral

webdev:wordpress:translations:wpml

Translations with WPML

wpml-config.xml

Example : force a custom field to be copied and synced with it's translations

<wpml-config>
	<custom-fields>
		<custom-field action="copy">pdf-test</custom-field>
	</custom-fields>
</wpml-config>

The field can only be updated from the main langage, but is garanteed to be the same on all langages.

Plugin / Theme translation

https://wpml.org/documentation/support/achieving-wpml-compatibility-for-your-themes-and-plugins/ - https://wpml.org/documentation/support/language-configuration-files/

Apparemment on a besoin de ces 3 plugins : WPML core, WPML String Translation and WPML Translation Management C'est juste leur Doc qui est mal expliquée

Constante pour récupérer la langue actuelle

Yes you can make use of WPML Constant ICL_LANGUAGE_CODE

For more information please check following URL
http://wpml.org/documentation/support/wpml-coding-api/

Récupérer l'ID du Term original depuis celle d'un Term traduit

Post du forum

$original_tax_id = icl_object_id( $Term_Obj->term_id, 'service_technique_taxonomy', false, 'fr');
webdev/wordpress/translations/wpml.txt · Dernière modification: 02/11/2017 18:19 de dolo