projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
df9864e
)
Fix mime type for CSV files, RT#1526
author
mark
<mark>
Tue, 19 Jan 2010 03:24:27 +0000
(
03:24
+0000)
committer
mark
<mark>
Tue, 19 Jan 2010 03:24:27 +0000
(
03:24
+0000)
httemplate/search/elements/search-csv.html
patch
|
blob
|
history
diff --git
a/httemplate/search/elements/search-csv.html
b/httemplate/search/elements/search-csv.html
index
2182270
..
9eb1b66
100644
(file)
--- a/
httemplate/search/elements/search-csv.html
+++ b/
httemplate/search/elements/search-csv.html
@@
-39,7
+39,10
@@
my $rows = $args{'rows'};
my %opt = %{ $args{'opt'} };
#http_header('Content-Type' => 'text/comma-separated-values' ); #IE chokes
my %opt = %{ $args{'opt'} };
#http_header('Content-Type' => 'text/comma-separated-values' ); #IE chokes
-http_header('Content-Type' => 'text/plain' );
+#http_header('Content-Type' => 'text/plain' );
+http_header('Content-Type' => 'text/csv' ); # So saith RFC 4180
+http_header('Content-Disposition' =>
+ 'attachment;filename="'.($opt{'name'} || PL($opt{'name_singular'}) ).'.csv"');
my $quote_char = '"';
$quote_char = $opt{csv_quote} if exists($opt{csv_quote});
my $quote_char = '"';
$quote_char = $opt{csv_quote} if exists($opt{csv_quote});