Forum Discussion
hooleylist
Feb 16, 2010Cirrostratus
Great that you figured it out. You could also try something like this:
when HTTP_REQUEST {
Check if the query string contains a parameter named attachment with a value of 1
if {[URI::query [HTTP::uri] "attachment"] == 1}{
set check_response 1
} else {
set check_response 0
}
}
when HTTP_RESPONSE {
if { $check_response } {
HTTP::header replace Content-Disposition [string map -nocase "inline attachment" [HTTP::header Content-Disposition]]
}
}
Aaron
edited to add HTTP::query to URI::query command...