0

My website is in English Language and using WordPress.

Html Code contains lang="en-US" only.

But I want some of the page in other language like Spanish, Arabic and German.

When I create new page it is by default lang="en-US".

How can I set this lang="es" or specific language attribute?

I have tried many plugins but all are converting every pages to selected languages that I don't want.

0

You mentioned that you want:

some of the page in other language like Spanish, Arabic and German.

By "some" do you mean a few lines in one page are written in a foreign language, or that some pages of your entire website are in a foreign language?

Because if your entire content is English and you just need to write a few lines or paragraphs in a foreign language you should be able to do that and then write styles to render them correctly (like adding direction: rtl for Arabic text).

In the case of the latter (some pages being in a foreign language), perhaps you could create a custom template for those pages with the appropriate tags and apply them? So you would have the Default Template, Arabic, German, and Spanish Template all show up as options in your Page settings.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.