Advertisement:

Author Topic: What is the usage difference between _e("hello"), _m("hello") and __("hello") ?  (Read 190 times)

AdrianOlmedo

  • Newbie
  • *
  • Posts: 46
  • Working with Osclass 3.7.5
What is the usage difference between _e("hello"), _m("hello") and __("hello") ?

calinbehtuk

  • Sr. Member
  • ****
  • Posts: 478
Different cases for translation purposes

_m('your message'); is used for info or warning messages by the system (this will return)

_e('your text','domain'); is used by themes and plugins in most cases (this will echo the result)

__('your text');the default translation function (this will return)

You can see these functions in oc-includes/osclass/helpers/hTranslation.php

<?php _e('Some text','theme_name'); ?>
<?php echo _m('Some text'); ?>
<?php echo __('Some text'); ?>

AdrianOlmedo

  • Newbie
  • *
  • Posts: 46
  • Working with Osclass 3.7.5
Thank you!