Static home page with hard-coded layout (4 posts)

  1. ganeshas
    Posted 3 years ago #


    I am trying to find a solution for the following problem:

    I created a static home page in English with all the text hard-coded in front-page.php

    Now I am trying to have it translated into Polish using Polylang. I understand that it will not translate the hard-coded text, but I thought I could do the following:

    I set up a template for the Polish version of the page (hard-coded the Polish text in it again) and added it to the Polish version of the home page: http://www.magdakorwin.co.uk/pl

    Unfortunately, the page is not picking up the template, it still displays the default, hard-coded English home page.

    Any help would be much appreciated.


  2. Chouby
    Plugin Author

    Posted 3 years ago #

    It won't work this way.

    But you can use the po/mo files to translate your hardcoded text just as it is done by WordPress, themes and plugins by following the instructions here

  3. ganeshas
    Posted 3 years ago #

    Hi Chouby,

    This is very promising, but being a basic WP user, I need a bit more explanation, if possible, please.

    1. With the above solution (internationalization) would the text be automatically translated or would it be possible to have it translated manually?

    2. I am not using strings in my theme. What would the strings be in my home page? Would it be all the text I have there?

    3. An other solution I was thinking of is having Advanced Custom Fields plugin on my home page - would that be compatible with the Polylang plugin?

    Please advise me if any of my thinking is right. Thank you.

  4. Chouby
    Plugin Author

    Posted 3 years ago #

    1. There is no automatic translation when you use the internationalization functions of WordPress. You must manually create the po/mo files.

    2. You can internaltionalize all the text of your front page

    3. There is some adapatation to do to make Advanced Custom Fields and Polylang work together.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Polylang
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic