saveDocument() function from NSIWebBrowserPersist
As far as I know, 'save as..' feature from Firefox browser also uses this function, so I tried to implement this function in my code. All went well except the saved css and javascript files. They contain weird numbers. 'Save as..' from Firefox does not do this. Did I do something wrong? What I did: webBrowserPersist.saveDocument(content.document, file, dir, null, null, null); Did I miss something? Am I supposed to change MIME or encoding flags? (I don't understand these 4th and 5th parameters by the way) Thanks in advance. https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XPCOM/Reference