Hi
I think it patch can help users with not iso8859-1 charsets
(I use koi8-r :-) )
Michael.
---
ApacheJSSI-1.1/src/java/org/apache/servlet/ssi/PageParserServlet.java.orig
+++
ApacheJSSI-1.1/src/java/org/apache/servlet/ssi/PageParserServlet.java
@@ -130,6 +130,12 @@
private boolean bufferedOutput = false;
/**
+ * a string specifying the charset
+ * document charset
+ */
+ private String charset = null;
+
+ /**
* Initialize PageParser.
* @param config servlet configuration, stored by superclass
* @exception ServletException passed on from superclass
@@ -178,6 +184,8 @@
bufferedOutput=b.toUpperCase().startsWith("Y")
|| b.equals("1");
}
+ if(config.getInitParameter ("charset") != null)
+ charset=config.getInitParameter ("charset");
}
/**
@@ -204,7 +212,10 @@
public void doGet(HttpServletRequest req, HttpServletResponse res)
throws ServletException, IOException {
- res.setContentType("text/html");
+ if (charset != null)
+ res.setContentType("text/html; charset="+charset);
+ else
+ res.setContentType("text/html");
// parse file contents
String path = req.getPathTranslated();
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]