ImportEnv UDM_TEST_DBADDR0 ImportEnv UDM_TEST_DIR DBAddr $(UDM_TEST_DBADDR0)?dbmode=single CVSIgnore yes Disallow */CVS/* SaveSectionSize no DetectClones no AddType text/html *.html AddType text/plain *.txt Section body 1 128 Section title 1 128 Section HTTP.Content 0 0 Section HTTP.LocalCharsetContent 0 0 # Replace Content-Type for a specific URL Section content-type 0 64 afterheaders cdoff "" "${URL}" ".*test1.txt" "text/html" # Replace Content-Type for a specific Content Section content-type 0 64 afterheaders cdoff "" "${HTTP.Content}" ".*.*" "text/html" # Check that afterheaders + ${HTTP.LocalCharsetContent} don't work. Section lccah 0 64 afterheaders cdoff "" "${HTTP.LocalCharsetContent}" "<html>.*<head>.*<title>" "this is html" # Check that afterguesser + ${HTTP.LocalCharsetContent} work. Section lccag 0 64 afterguesser cdoff "" "${HTTP.LocalCharsetContent}" "<html>.*<head>.*<title>" "this is html" # This one should be replaced to text/html using URL Server page http://site/test1.txt file:$(UDM_TEST_DIR)/htdocs/test1.txt # This one should be replaced to text/html using HTTP.Content Server page http://site/test2.txt file:$(UDM_TEST_DIR)/htdocs/test2.txt # This one should be kept text/plain Server page http://site/testa.txt file:$(UDM_TEST_DIR)/htdocs/test1.txt