Why I have developed a plug-in
I decided to write this plugin for two reasons: the first is that developing a plugin gives me the chance to meet new problems and to learn from them, the other is that my mother tongue is Italian, and I was tired of translating every post personally 🙂
Obviously, there are other plugins that do this job even better, but I was not in great need of features: my aim was to write in Italian and see my published content in English. Nothing more, nothing less.
This is exactly what the “Easy Translate” can do.
What is this plugin
As mentioned above, “Easy Translate” allows you to write your own content in one language and, when you press the button “publish”, translate everything into another language.
It’s all here.
If you don’t need a plugin heavy and expensive with lots of features and just want something that will allow you to simply write in your language and translate to the publication, then this plugin is for you. (it is still in the development stage, pay attention to the Bugs section)
How it works
The plugin is fully open source, the code is visible here.
The translations are performed using the service of Yandex.
Yandex allows to use their API in the free version, and the limits to be respected to use the free version are very generous: 1000000 characters for the day and 10000000 characters for the month.
Certainly for the professional bloggers are not that great, but for a personal blog like mine should be more than good (and I think they go well for many of you).
The plugin uses the filter
wp_insert_post_data , which allows you to intercept the content of the post or page before being saved in the database, to add the Yandex signature an the end of the post, and the Gutenberg API to translate the content of your editor. In this way, you can translate everything with one click and review the translation directly in your editor, before publishing.
All very simple and banal.
Settings of the plugin
Once installed and activated, a new menu will be available in the sidebar.
Inside you will find the plugin settings.
You can request an API key for free here.
After obtaining it, you simply have to copy and paste it here in the settings
The choice of the language
Quite simply, you need to set your native language and the language you want to translate your content.
You have to insert a valid API Key and save the settings, in order to be able to choose the languages.
In case you have the pro version of Yandex, you can disable the display of this text.
Plugin in action
Once saved the settings, you will have a new button in the editor:
This button will open a sidebar, where (at the moment) there is the “translate” button.
Once you have your content, just open the sidebar and click on “Translate your content”.
Now you should see your content translated in the editor. You can read the translation and fix the errors. Then finally publish your translated content.
Things to keep in mind
The plugin is developed entirely by me in my free time. This means that you may encounter a few bugs during its use.
If you’re a developer, you are free to play with the code and open a PR on GitHub, I’d be really happy.
If you are not a developer, you can still help me maintain and improve this plugin by simply opening an “issue” on GitHub. I will try to fix the problem as soon as possible.
The quality of The translation
This post is my first post completely translated from the plugin “Easy Translate”. I don’t want to do revisions or to correct it manually, just to show how translation quality can offer the free API of Yandex.
Surely there are mistakes, but from a free service it is impossible to ask for more.
If you decide to use this plugin, you have to be aware of its limits, and its limits of them, you can clearly read in this content.
The advice I can give you, as long as I will not have integrated other systems of translation (it is a point on the list to-do) is to try to write in a simple way, in order to facilitate the work of Yandex and minimize errors.
Powered by Yandex.Translate.