Skip to content
Snippets Groups Projects
Commit 540098cd authored by Jared Hancock's avatar Jared Hancock
Browse files

i18n: Fix incorrect creation of PO file

parent 1ccbb165
No related branches found
No related tags found
No related merge requests found
...@@ -57,7 +57,7 @@ if (isset($options['entry']) && $options['mode'] == 'edit') { ?> ...@@ -57,7 +57,7 @@ if (isset($options['entry']) && $options['mode'] == 'edit') { ?>
if (($a = $field->getAnswer()) && $a->isDeleted()) { if (($a = $field->getAnswer()) && $a->isDeleted()) {
?><a class="action-button danger overlay" title="Delete this data" ?><a class="action-button danger overlay" title="Delete this data"
href="#delete-answer" href="#delete-answer"
onclick="javascript:if (confirm('You sure?')) onclick="javascript:if (confirm('<?php echo __('You sure?'); ?>'))
$.ajax({ $.ajax({
url: 'ajax.php/form/answer/' url: 'ajax.php/form/answer/'
+$(this).data('entryId') + '/' + $(this).data('fieldId'), +$(this).data('entryId') + '/' + $(this).data('fieldId'),
......
...@@ -435,7 +435,7 @@ class i18n_Compiler extends Module { ...@@ -435,7 +435,7 @@ class i18n_Compiler extends Module {
// Unescape single quote (') and escape unescaped double quotes (") // Unescape single quote (') and escape unescaped double quotes (")
$string = preg_replace(array("`\\\(['$])`", '`(?<!\\\)"`'), array("$1", '\"'), $string); $string = preg_replace(array("`\\\(['$])`", '`(?<!\\\)"`'), array("$1", '\"'), $string);
// Preserve embedded newlines -- preserve up to on // Preserve embedded newlines -- preserve up to on
$string = preg_replace("`\n\s*`u", "\\n\n", $string); $string = preg_replace("`\n`u", "\\n\n", $string);
// Word-wrap long lines // Word-wrap long lines
$string = rtrim(preg_replace('/(?=[\s\p{Ps}])(.{1,76})(\s|$|(\p{Ps}))/uS', $string = rtrim(preg_replace('/(?=[\s\p{Ps}])(.{1,76})(\s|$|(\p{Ps}))/uS',
"$1$2\n", $string), "\n"); "$1$2\n", $string), "\n");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment