fix nature absolute links and redirect (to http, then https, sigh)
[via-proxy] / p.vbz.ffzg.hr.conf
index 446d742..8755ea1 100644 (file)
@@ -484,10 +484,10 @@ FilterChain NEWPATHS2
        Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3"
        Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1"
 
-       Header edit* Location "https://([^/]*.nature.com)/" "https://$1.p.vbz.ffzg.hr/"
+       Header edit* Location "https?://([^/]*.nature.com)/" "https://$1.p.vbz.ffzg.hr/"
 
 RequestHeader unset Accept-Encoding
-Substitute "s|http://www.nature.com/|https://www.nature.com.p.vbz.ffzg.hr/|n"
+Substitute "s|https://www.nature.com/|https://www.nature.com.p.vbz.ffzg.hr/|n"
 FilterDeclare NEWPATHS2
 FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|"
 FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|"
@@ -652,6 +652,15 @@ FilterChain NEWPATHS2
        Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3"
        Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1"
 
+       RequestHeader unset Accept-Encoding
+       Substitute "s|https://www.scopus.com|https://www.scopus.com.p.vbz.ffzg.hr|"
+       FilterDeclare NEWPATHS
+       FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/html|"
+       FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/css|"
+       FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|"
+       FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|"
+       FilterChain NEWPATHS
+
        CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined
 </VirtualHost>