PD4ML v4 Forums PD4ML v3 Archived Forums (Read Only) Troubleshooting Problem with internet explorer and special characters

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #26408

    Hi, i’m triying to generate a pdf file from a servlet (a filter-servlet to be specific) the thing is that the html that i’m trying to convert have special characters (á é í ó ú ñ) but they are all in the ISO-8859-1 encoding, when i open the URL with firefox all works ok but when i try to open the url with IE the special characters does not render ok, this is my code:
    <br /> //the important part of the code<br /> PD4ML pd4ml = new PD4ML();<br /> <br /> pd4ml.setPageInsets(new Insets(20, 10, 10, 10));<br /> pd4ml.setHtmlWidth(800);<br /> pd4ml.setPageSize(pd4ml.changePageOrientation(PD4Constants.LETTER));<br /> <br /> response.setContentType("application/pdf");<br /> response.setCharacterEncoding("ISO-8859-1");<br /> pd4ml.enableDebugInfo();<br /> ByteArrayOutputStream salida = new ByteArrayOutputStream();<br /> <br /> pd4ml.render(new StringReader(preProcessPage), salida ,new URL("http://"+<br /> request.getServerName()+":"+request.getLocalPort()+<br /> this.getFilterConfig().getServletContext().getContextPath()),"ISO-8859-1");<br /> <br /> response.setContentLength(salida.size());<br /> <br /> response.getOutputStream().write(salida.toByteArray());<br /> response.getOutputStream().close();<br /> <br /> //more code<br />

    The weird thing is that the code works perfect in firefox, maybe the problem is the internet explorer or the pdf plugin, any ideas? thanks….

Viewing 1 post (of 1 total)

The forum ‘Troubleshooting’ is closed to new topics and replies.