0

currently I have this code:

<?php _e( 'Follow ' . get_bloginfo( 'name' ) . ' on Facebook', 'yanse' ); ?>

But I just get Follow to translate and it echoes "Seguir 'Site name' on Facebook"

5

You can use sprintf:

echo sprintf( __('Follow %s on Facebook', 'yanse'), get_bloginfo('name') );
  • Thanks, I know. What I want to translate is the following text "on Facebook" – aurrutia Apr 18 '16 at 4:34
  • I have updated the answer. Hope it work for you! – MinhTri Apr 18 '16 at 5:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.