Hook Function to Footer
You can create one block and add the html content and place this block in the footer region. This content will place inside the  tag and after the main content. Thats mean you will get your content before the closing  tag.