Re: 'accounts/logout' isn't working !!

2024-03-14 Thread Keshav Jha
New Version of django does not support GET method for logout. You have two options to accomplish your task: 1. Send a post request to logout. 2. Custom Manage: > Create a custom url in the project's url.py at the top. path('admin/logout/', logout_), > Create a v

Re: 'accounts/logout' isn't working !!

2024-02-22 Thread AshiQul Islam Munna
Tried! But not worked! I find a solution - Called url in templete with a form and csrf token. On Thu, 22 Feb 2024, 9:29 pm Adisa Habeebulah, wrote: > Remove the LOGOUT_REDIRECT_URL from the settings > That should solve the problem > > > On Thu, Feb 22, 2024, 3:02 PM Okechukwu Ogo > wrote: > >

Re: 'accounts/logout' isn't working !!

2024-02-22 Thread AshiQul Islam Munna
I didn't use custom url, just added auth default url to url in my project 'path("accounts/", include("django.contrib.auth.urls")),and called login, logout url in template. Login works perfectly but logout does not work. On Thu, 22 Feb 2024, 8:03 pm Okechukwu Ogo, wrote: > Check your logout URL

Re: 'accounts/logout' isn't working !!

2024-02-22 Thread Adisa Habeebulah
Remove the LOGOUT_REDIRECT_URL from the settings That should solve the problem On Thu, Feb 22, 2024, 3:02 PM Okechukwu Ogo wrote: > Check your logout URL and view if there's a mistake > > On Thu, 22 Feb 2024, 14:27 AshiQul Islam Munna, > wrote: > >> Hello! >> >> I am using default auth system

Re: 'accounts/logout' isn't working !!

2024-02-22 Thread Okechukwu Ogo
Check your logout URL and view if there's a mistake On Thu, 22 Feb 2024, 14:27 AshiQul Islam Munna, wrote: > Hello! > > I am using default auth system in my project these steps- > > 1. Add this in my project urls path("accounts/", include( > "django.contrib.auth.urls")), > > 2. Create HTML file

'accounts/logout' isn't working !!

2024-02-22 Thread AshiQul Islam Munna
Hello! I am using default auth system in my project these steps- 1. Add this in my project urls path("accounts/", include( "django.contrib.auth.urls")), 2. Create HTML file in -'templates/registration/login.html' 3. In 'base.html' i wrote - ' {% if user.is_authenticated %} Hi {{ user.