diff options
| author | Mark Wells <mark@freeside.biz> | 2014-04-11 15:12:22 -0700 |
|---|---|---|
| committer | Mark Wells <mark@freeside.biz> | 2014-04-11 15:12:22 -0700 |
| commit | b3cecd1976e92c32740c3e2e1227a7d718e07b57 (patch) | |
| tree | 57972f0650b8cca5c45d17f70016962f6b844bf5 /httemplate/search/elements | |
| parent | bd4e387da29dc3dad44605572d531ab4f7ab4f4d (diff) | |
477 report, XML adjustments, #28020
Diffstat (limited to 'httemplate/search/elements')
| -rw-r--r-- | httemplate/search/elements/search-xml.html | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/httemplate/search/elements/search-xml.html b/httemplate/search/elements/search-xml.html index 50b191610..18bfe8d82 100644 --- a/httemplate/search/elements/search-xml.html +++ b/httemplate/search/elements/search-xml.html @@ -32,9 +32,11 @@ my $header = $args{'header'}; my $rows = $args{'rows'}; my %opt = %{ $args{'opt'} }; +my $filename = $opt{'filename'} || + ($opt{'name'} || PL($opt{'name_singular'}) . 'xml'); + http_header('Content-Type' => 'application/XML' ); # So saith RFC 4180 -http_header('Content-Disposition' => - 'attachment;filename="'.($opt{'name'} || PL($opt{'name_singular'}) ).'.xml"'); +http_header('Content-Disposition' => 'attachment;filename="'.$filename.'"'); unless ( $opt{'fields'} ) { foreach my $i ( 0 .. ( $#{ @$rows[0] } ) ) { |
