Mercurial Hosting > luan
comparison src/goodjava/webserver/handlers/ContentTypeHandler.java @ 1734:02d2a6c3bc6f
content-types for doc and docx
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Sun, 18 Sep 2022 15:38:27 -0600 |
parents | 8a6e48371c66 |
children | a02a75e3daa8 |
comparison
equal
deleted
inserted
replaced
1733:8b3ad1fb219f | 1734:02d2a6c3bc6f |
---|---|
31 map.put( "jpeg", "image/jpeg" ); | 31 map.put( "jpeg", "image/jpeg" ); |
32 map.put( "png", "image/png" ); | 32 map.put( "png", "image/png" ); |
33 map.put( "gif", "image/gif" ); | 33 map.put( "gif", "image/gif" ); |
34 map.put( "pdf", "application/pdf" ); | 34 map.put( "pdf", "application/pdf" ); |
35 map.put( "woff", "font/woff" ); | 35 map.put( "woff", "font/woff" ); |
36 map.put( "doc", "application/msword" ); | |
37 map.put( "docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document" ); | |
36 // add more as need | 38 // add more as need |
37 } | 39 } |
38 | 40 |
39 public static String getExtension(String path) { | 41 public static String getExtension(String path) { |
40 int iSlash = path.lastIndexOf('/'); | 42 int iSlash = path.lastIndexOf('/'); |