title: How to do HTML to XML conversion to generate closed tags?
body: <p>How to do xml to html conversion to generate closed tags.</p>
  
  <p>The context is explained here: <a href="https://stackoverflow.com/questions/26648853/error-while-generating-pdf-from-html-file-in-java-using-itext">Error while generating pdf from Html file in Java using iText</a></p>
  
  <p>When I try converting html to pdf using iText and XML Worker, I'm asked to give the closing tag for <code>&lt;hr&gt;</code> and <code>&lt;br&gt;</code> tags. It works if I do this manually: conversion to pdf worked! But I don't want to add each closing tag manually. How can I do this in an automated way? </p>