diff --git a/developer_manual/core/translation.rst b/developer_manual/core/translation.rst index ee83e7df4..7fafa9e79 100644 --- a/developer_manual/core/translation.rst +++ b/developer_manual/core/translation.rst @@ -48,10 +48,18 @@ What about variable in the strings? If you need to add variables to the translation strings do it like this: +PHP: + .. code-block:: php $l->t('%s is available. Get more information', array($data['versionstring'], $data['web'])); +JavaScript: + +.. code-block:: javascript + + t(appName, '{name} is available. Get more information', {name: 'Nextcloud 16', link: '...'}); + Automated synchronization of translations -----------------------------------------