AnsweredAssumed Answered

Encoding Problem

Question asked by mangar on Jan 9, 2013
Latest reply on Jan 10, 2013 by mangar
I have a simple text file in Alfresco that has this content in it:  “Generic Table Template”

I have this code:
       ContentReader reader = contentService.getReader(node, ContentModel.PROP_CONTENT);
       if(reader != null) {
          System.out.println("Writing File:"+filename);
          System.out.println("Default encoding:"+reader.getEncoding());
         File f = new File(filename);
         reader.getContent(f);
       }

The default encoding is showing up correctly as UTF-8

however, when I look at the written file I see this:   ���Generic Table Template���

Any Ideas?

Outcomes