gitweb: Decode long title for link tooltips
This is a simple one liner to decode long title string in perl's internal form to utf-8 for link tooltips. This is not crucial if the commit message is all in ASCII, however, if you decide to use other encoding, such as UTF-8, tooltips ain't readable any more. Signed-off-by: Yasushi SHOJI <yashi@atmark-techno.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
Yasushi SHOJI committed
Sep 27, 2006 at 12:04 UTC
4a0641b7cf833644b286b56bb57d66b5538e4418
1 file changed
+1
-1
gitweb/gitweb.perl
+1
-1
@@ -617,7 +617,7 @@ sub format_subject_html {
617
618
if (length($short) < length($long)) {
619
return $cgi->a({-href => $href, -class => "list subject",
620
- -title => $long},
620
+ -title => decode("utf8", $long, Encode::FB_DEFAULT)},
621
esc_html($short) . $extra);
622
} else {
623
return $cgi->a({-href => $href, -class => "list subject"},