Jump to content

Question about multi language


Recommended Posts

Hello guys, hope you all have a great day.

so I want to translate my templates element based on selected languages i.e "read more" button, "follow me" button, etc. in wordpress we can do something like this

<?php _e( 'Some text to translate and display.', 'textdomain' ); ?>

and then translate it via .mo files,

how to achieve similar to this using PW or is there better way doing this? 

Link to comment
Share on other sites

$out = $this->_("Live long and prosper");  // syntax within a class

$out = __("Live long and prosper!"); // syntax outside of a class

All the information you need is right here in the docs.

thank you!!...didn't see that. I think I need more coffee  :P

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...