gitweb: Add link to "project_index" view to "project_list" page
Add link to "project_index" view as [TXT] beside link to "opml" view, (which is marked by [OPML]) to "project_list" page. While at it add alternate links for "opml" and "project_list" to HTML header for "project_list" view. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
Jakub Narebski committed
Sep 15, 2006 at 11:11 UTC
9d0734ae49c8c0a5a2c6b6bf85011d095182e357
1 file changed
+10
-1
gitweb/gitweb.perl
+10
-1
@@ -1255,6 +1255,13 @@ EOF
1255
printf('<link rel="alternate" title="%s log" '.
1256
'href="%s" type="application/rss+xml"/>'."\n",
1257
esc_param($project), href(action=>"rss"));
1258
+ } else {
1259
+ printf('<link rel="alternate" title="%s projects list" '.
1260
+ 'href="%s" type="text/plain; charset=utf-8"/>'."\n",
1261
+ $site_name, href(project=>undef, action=>"project_index"));
1262
+ printf('<link rel="alternate" title="%s projects logs" '.
1263
+ 'href="%s" type="text/x-opml"/>'."\n",
1264
+ $site_name, href(project=>undef, action=>"opml"));
1265
}
1266
if (defined $favicon) {
1267
print qq(<link rel="shortcut icon" href="$favicon" type="image/png"/>\n);
@@ -1309,7 +1316,9 @@ sub git_footer_html {
1316
-class => "rss_logo"}, "RSS") . "\n";
1317
} else {
1318
print $cgi->a({-href => href(project=>undef, action=>"opml"),
1312
- -class => "rss_logo"}, "OPML") . "\n";
1319
+ -class => "rss_logo"}, "OPML") . " ";
1320
+ print $cgi->a({-href => href(project=>undef, action=>"project_index"),
1321
+ -class => "rss_logo"}, "TXT") . "\n";
1322
}
1323
print "</div>\n" .
1324
"</body>\n" .