From bc36e5ac5ca2c5fa0f11c7b279092da7d275dc7e Mon Sep 17 00:00:00 2001 From: koha-preprod Date: Mon, 7 Feb 2011 15:59:18 -0500 Subject: [PATCH] Bug 5709: Add the ability to translate HTML5 placeholder text in an input field Signed-off-by: Kyle M Hall Signed-off-by: Paul Poulain Signed-off-by: Jared Camins-Esakov --- misc/translator/tmpl_process3.pl | 2 +- misc/translator/xgettext.pl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/misc/translator/tmpl_process3.pl b/misc/translator/tmpl_process3.pl index 89c993f672..cd46997c79 100755 --- a/misc/translator/tmpl_process3.pl +++ b/misc/translator/tmpl_process3.pl @@ -59,7 +59,7 @@ sub text_replace_tag ($$) { # value [tag=input], meta my $tag = lc($1) if $t =~ /^<(\S+)/s; my $translated_p = 0; - for my $a ('alt', 'content', 'title', 'value','label') { + for my $a ('alt', 'content', 'title', 'value', 'label', 'placeholder') { if ($attr->{$a}) { next if $a eq 'label' && $tag ne 'optgroup'; next if $a eq 'content' && $tag ne 'meta'; diff --git a/misc/translator/xgettext.pl b/misc/translator/xgettext.pl index 99a75bf372..032117d5bd 100755 --- a/misc/translator/xgettext.pl +++ b/misc/translator/xgettext.pl @@ -102,7 +102,7 @@ sub text_extract (*) { } elsif ($kind eq C4::TmplTokenType::TAG && %$attr) { # value [tag=input], meta my $tag = lc($1) if $t =~ /^<(\S+)/s; - for my $a ('alt', 'content', 'title', 'value','label') { + for my $a ('alt', 'content', 'title', 'value', 'label', 'placeholder') { if ($attr->{$a}) { next if $a eq 'label' && $tag ne 'optgroup'; next if $a eq 'content' && $tag ne 'meta'; -- 2.39.5