why does django encapsulate all the content inside the body tag?

This is not a django issue.

The html tag can only have a head and body tag inside it. Your footer and script should go inside the body.

Your web browser have detected that the structure of your document is not valid and have corrected it.

If you check the HTML source code of your page (instead of using the dev tools), you will see that the template is rendered as you write it.

So move all your page content in the body tag.

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top