Django session data lost

I am new to Django, so forgive me for any beginner mistakes. I am experiencing an issue where the session data is being lost when a user tries to navigate on my site after logging in. I am making this website on W3Schools (I know it's not a great resource already), and have attached some images of my code home html code and some of my views. Specifically, I will log a user in successfully and the user is sent back to the home page with their session info intact, but as soon as I press the home button on the navbar or any other implemented buttons the session info is lost. In the database, the session info is still there, so it has not been deleted, just lost. Thanks for the help!

[enter image description here](https://i.sstatic.net/wi7dLWnY.png)
[enter image description here](https://i.sstatic.net/E42uA8IZ.png)
[enter image description here](https://i.sstatic.net/VCyNa8Kt.png)

I logged some messages to confirm that the session data was lost after being sent to the URLs 'profile' and 'home' from the home page. I do not mess with session data anywhere other than logging the user in.

Вернуться на верх