WordPress Plugin Development Tutorial - Adding languages and Internationalization - Pricode

Поділитися
Вставка
  • Опубліковано 19 вер 2024
  • In this video, following our WordPress Plugin tutorial , let's add language translations to our plugin using POEDIT, xgettext and WP-CLI.
    I would like to know your opinions, leave a comment and click on the like button as many times as you can.
    Stay tuned to the channel for more useful content.
    //Github
    github.com/Pri...
    //Pricode Website
    pricode.io
    //Twitter
    / pricoders
    //Instagram
    / aldinomad
    #wordpress #wordpresstutorial #developers #development
    Music by Ru Frequence / moon

КОМЕНТАРІ • 18

  • @Pricoders
    @Pricoders  2 роки тому

    Any questions you have just leave a comment, I will be pleased to listen and help all of you!

  • @onelook1870
    @onelook1870 5 місяців тому +1

    Thanks for the tutorial

    • @Pricoders
      @Pricoders  5 місяців тому +1

      Our pleasure

    • @onelook1870
      @onelook1870 5 місяців тому +1

      @@Pricoders Did my first translation watching the tutorial. Thank you!

  • @BakiGoxhaj
    @BakiGoxhaj 4 місяці тому +1

    Great tutorial, well done!
    You could try to keep a faster pace - it would help I think.

    • @Pricoders
      @Pricoders  4 місяці тому

      I am doing my best, I hope the upcoming times I can really add a good pace. Thanks for the comment!

  • @BasDeBom
    @BasDeBom Рік тому

    Thanks man! I used your vid to translate a plugin and it works. Side note: I did get a fatal error while creating a .pot file due to memory shortage. I fixed that by increasing the PHP_MEMORY in the php.ini file from WP_CLI. It could be helpful for other programmers. Thanks again!

    • @Pricoders
      @Pricoders  Рік тому

      It is my pleasure, the idea is that everybody learn something, thanks for the comment!

  • @NagatoKamiPain
    @NagatoKamiPain 9 місяців тому +1

    how can you translate JS file that have hardcoded values in it? for example line 51 (lets pretend you cant use php tag)

    • @Pricoders
      @Pricoders  9 місяців тому +1

      You can look on Google "JS unobfuscation"

    • @Pricoders
      @Pricoders  9 місяців тому +1

      For some reason I totally misunderstood the question, the way to do this is either setup the value by php or by i18n.js file

  • @hieutongdang3149
    @hieutongdang3149 Рік тому +1

    With this way can I translate the data from the database out?

    • @Pricoders
      @Pricoders  Рік тому +1

      no, this is a cached laguange translation

    • @hieutongdang3149
      @hieutongdang3149 Рік тому

      @@Pricoders Is there a way to translate language data stored in phpmyadmin?

  • @hieutongdang3149
    @hieutongdang3149 Рік тому

    Thank you , I have created my own plugin , but I want Adding languages ​​and Internationalization for my javascript file ? Do you have any ideas for me?

    • @Pricoders
      @Pricoders  Рік тому

      You can either create a backend in ajax that allows you to setup the localization with WordPress. or you can simply setup an array with your languages and get the lang of the browser

    • @hieutongdang3149
      @hieutongdang3149 Рік тому +1

      @@Pricoders thanks you

    • @Pricoders
      @Pricoders  Рік тому

      Our pleasure