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
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:
>
>
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
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
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
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.
6 matches
Mail list logo