Skip to content

Commit

Permalink
Merge branch 'gb/gitweb-opml'
Browse files Browse the repository at this point in the history
* gb/gitweb-opml:
  gitweb: suggest name for OPML view
  gitweb: don't use pathinfo for global actions
  • Loading branch information
Junio C Hamano committed Jan 18, 2009
2 parents 8f31355 + ae35785 commit 094f75b
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions gitweb/gitweb.perl
Original file line number Diff line number Diff line change
Expand Up @@ -834,7 +834,7 @@ (%)
}

my $use_pathinfo = gitweb_check_feature('pathinfo');
if ($use_pathinfo) {
if ($use_pathinfo and defined $params{'project'}) {
# try to put as many parameters as possible in PATH_INFO:
# - project name
# - action
Expand All @@ -849,7 +849,7 @@ (%)
$href =~ s,/$,,;

# Then add the project name, if present
$href .= "/".esc_url($params{'project'}) if defined $params{'project'};
$href .= "/".esc_url($params{'project'});
delete $params{'project'};

# since we destructively absorb parameters, we keep this
Expand Down Expand Up @@ -6222,7 +6222,11 @@ sub git_atom {
sub git_opml {
my @list = git_get_projects_list();

print $cgi->header(-type => 'text/xml', -charset => 'utf-8');
print $cgi->header(
-type => 'text/xml',
-charset => 'utf-8',
-content_disposition => 'inline; filename="opml.xml"');

print <<XML;
<?xml version="1.0" encoding="utf-8"?>
<opml version="1.0">
Expand Down

0 comments on commit 094f75b

Please sign in to comment.