How to translate a theme ?


I want to implement a translate system for an omeka theme.
I already realised this operation on a plugin, it works.
I used the function __() to translate the strings. I created a .po file and I compiled this one to get a .mo file. That I put in the languages folder.
But the problem is that I dont find the solution for themes, that's why I need your help.

Thank you in advance.

Most of the pieces of translation work the same in themes as in plugins.

The main difference is that you need to be calling add_translation_source in your theme's custom.php, rather than in an initialize hook as you would in a plugin.

It works, thanks you.