html document is actually updated
Where are the output statements that write the results to the file?
There are several code examples on this site that write to files.
Use the Search
Add the following to your code to see what is output:
// Now output the doc
BufferedWriter bw = new BufferedWriter(new FileWriter(outFN));
kit.write(bw, doc, 0, doc.getLength());
bw.close();
I tried this on an HTML file and found that the output was missing some text that was in the input file. >>> Don't recommend this as a way to EDIT an HTML file. It looses text!!