• hello oceanwp’ers

    how do make my child theme (based on oceanwp) change the language of string such as found in the blog page, and search pages?
    using mo and po files? what settings do i need to have in wordpress?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Theme Author oceanwp

    (@oceanwp)

    Hello, to change the language of the parent theme, you need to translate the pot file in the languages folder of the theme with poedit. If you want to add custom text, you can add the files of the parent theme in your child theme, then open them in your text editor and add your own texts.

    Thread Starter ricmetal

    (@ricmetal)

    hello again,
    in my case, i want the website to be PT_BR which there already exists a po file with the strings translated. can i use that po file?

    Theme Author oceanwp

    (@oceanwp)

    Hi, yes, if you see mistranslated words, feel free to correct them and if the file is not fully translated feel free to complete it too ??
    Then, you can them the files to me and I will include them in the theme.

    Thread Starter ricmetal

    (@ricmetal)

    so, how exactly do i change the language?
    oceanwp’s zip already contains the language i want with translations. EDIT maybe not, it has PT_BR
    ive also added the languages to the child theme through that function:

    function my_child_theme_locale() {
    load_child_theme_textdomain( ‘ocean’, get_stylesheet_directory() . ‘/languages’ );
    }
    add_action( ‘after_setup_theme’, ‘my_child_theme_locale’ );

    how do you i make the website show translated strings?
    i still get english strings, for instance in the search results, when i want to have them im Portuguese.

    • This reply was modified 6 years, 6 months ago by ricmetal.
    Theme Author oceanwp

    (@oceanwp)

    Hello, if the words are translated in the po file of your language, if you add your WordPress site in your language, it will replace the English words.

    Thread Starter ricmetal

    (@ricmetal)

    ok, i get. the website still doesn’t show in another language. this might be a problem from another plugin. any one or two steps i can follow to ensure this is not an oceapwp problem?

    i’m using es_ES, which comes with oceanwp, and i’m using the oceanwp theme (no childs), and set the website to spanish (assuming it the general es_ES)?

    i’d rather try and fix the problem, other that re-making the custom child theme.

    • This reply was modified 6 years, 6 months ago by ricmetal.
    Theme Author oceanwp

    (@oceanwp)

    Hello, this is very weird, yes if you select your language in WordPress, the language should work in front end, can you create a pre-purchase ticket on oceanwp.org? I will ask you more information and try to see what is wrong.

    Thread Starter ricmetal

    (@ricmetal)

    sorry, i had to resolve this fast so i reset my wordpress installation and rebuilt the website.

    on the plus side i’ll update the pt_PT language for OceanWP in the upcoming time!

    thanks for your time!

    Theme Author oceanwp

    (@oceanwp)

    You’re welcome, let me know if you need more help with this.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Language’ is closed to new replies.