Jump to content

Code Internationalization (i18n) and HTML tags output


LAPS
 Share

Recommended Posts

Hi, I'm translating my website (in particular, FormBuilder template files) using Code Internationalization (i18n).

When I use this code:

<?php echo sprintf(__('Some text and <a href="%1$s">link</a>'), 'http://www.link.com'; ?>

then it outputs plain text:

Some text and <a href="http://www.link.com">link</a>

How can I output the above string this way (no plain text):  Some text and link?

 

Update

I will use html_entity_decode(). What do you thing about?

 

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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...