HTML in translation
Pixelstyle - June 21, 2009 - 13:55
| Project: | ecard |
| Version: | 6.x-1.6 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Jump to:
Description
The confirmation message for a sent e-card contains html. If I try to translate the strings (there are actually two string cut in half on a link) Drupal tells me it contains html which is not allowed.
Can the two strings just become one and implement the html in another way?

#1
I too ran into this today. I needed a custom Dutch text.
This code works for me (ecard.module):
drupal_set_message(t('Your message has been sent and a copy is stored for your reference.<br />you can view the copy <a href="@card_copy_url">here</a>', array('@card_copy_url' => $card_copy_url)));Original code:
drupal_set_message(t("Your message has been sent and a copy is stored for your reference.<br />you can view the copy <a href='") . $card_copy_url . t("'>here</a>"));There is an example just like this here: http://api.drupal.org/api/function/t/6
#2
Works great! thanks!
#3
Should be fixed in the latest version.
#4
Automatically closed -- issue fixed for 2 weeks with no activity.