[buddypress-trac] [BuddyPress] #2703: [Translations] Cannot translate strings when actual new line breaks are used instead of \n
buddypress-trac at lists.automattic.com
buddypress-trac at lists.automattic.com
Wed Nov 3 09:48:01 UTC 2010
#2703: [Translations] Cannot translate strings when actual new line breaks are
used instead of \n
-----------------------+----------------------------------------------------
Reporter: calvin_42 | Owner:
Type: defect | Status: new
Priority: major | Milestone: 1.3
Component: Core | Keywords:
-----------------------+----------------------------------------------------
From the support thread [http://buddypress.org/community/groups/how-to-
and-troubleshooting/forum/topic/strings-containing-new-lines-like-emails-
content-are-not-translated/ Strings containing new lines like emails
content are not translated ].
Rather than using actual line breaks in strings, using \n and keeping
everything on one line resolves this issue. These strings are most of the
time the content of the notification emails.
For example, in [http://trac.buddypress.org/browser/branches/1.2/bp-groups
/bp-groups-notifications.php#L22 bp-groups-notifications.php:22] :
Replace :
{{{
$message = sprintf( __(
'Group details for the group "%s" were updated:
To view the group: %s
---------------------
', 'buddypress' ), $group->name, $group_link );
}}}
By:
{{{
$message = sprintf( __(
'Group details for the group "%s" were updated:\n\nTo view the group:
%s\n\n---------------------\n', 'buddypress' ), $group->name, $group_link
);
}}}
--
Ticket URL: <http://trac.buddypress.org/ticket/2703>
BuddyPress <http://buddypress.org/>
BuddyPress
More information about the buddypress-trac
mailing list