comparison src/goodjava/webserver/handlers/ContentTypeHandler.java @ 1772:f7b90d9a4639

add .ico
author Franklin Schmidt <fschmidt@gmail.com>
date Sun, 25 Jun 2023 15:21:08 -0600
parents db52c29605e2
children e647c92a4a12
comparison
equal deleted inserted replaced
1771:c62324841dfb 1772:f7b90d9a4639
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" ); 36 map.put( "doc", "application/msword" );
37 map.put( "docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document" ); 37 map.put( "docx", "application/vnd.openxmlformats-officedocument.wordprocessingml.document" );
38 map.put( "svg", "image/svg+xml" ); 38 map.put( "svg", "image/svg+xml" );
39 map.put( "ico", "image/x-icon" );
39 // add more as need 40 // add more as need
40 } 41 }
41 42
42 public static String getExtension(String path) { 43 public static String getExtension(String path) {
43 int iSlash = path.lastIndexOf('/'); 44 int iSlash = path.lastIndexOf('/');