authentication issue(Unable to login)

i am unable to authenticate user in my website

<html lang="en">

    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Jobseekers Login</title>
    <link rel="stylesheet" type="text/css" href="{% static 'jobglobel/css/userlogin.css' %}">
    <link rel="stylesheet" type="text/css" href="{% static 'jobglobel/css/font.css' %}">
    <link rel="shortcur icon" type="image/png" href="{% static 'jobglobel/images/worldwide.png' %}">

    <div class="div00">
            <h2>WelCome To</h2>
            <a href="{% url 'home' %}"><img class="img1" src="{% static 'jobglobel/images/worldwide.png' %}" alt=""></a>
            <a class="divjoba1" href="{% url 'home' %}">JobGlobeL</a>
            <p class="navp">WorldWide</p>
            <p class="navp1">Not Registered Yet?</p>
            <a href="{% url 'usersignup' %}"><button class="btn1">SIGNUP NOW</button></a>
            <p class="navp2">Here.</p>
    <div class="div1">
        <div class="div11">
            <p>JobSeeker's & Recruiters Login</p>
            <form class="formlogin" action="" method="POST" novalidate>
                {% csrf_token %}
                <div class="userdiv" >
                    <span class="sp" >* </span>{{form.username.label}} <br> {{form.username}} <span class="error" >{{form.username.errors|striptags}}</span>
                <div class="userpass">
                    <span class="sp" >* </span>{{form.password.label}} <br> {{form.password}} <span class="error" >{{form.password.errors|striptags}}</span> <br>
                <input class="submitbtn" type="submit" value="LOGIN">


```from django.shortcuts import redirect, render
from .forms import jobglobeluserform
from .models import jobglobeluser
from django.contrib.auth.forms import AuthenticationForm
from django.contrib.auth import authenticate,login,logout,views
from django.contrib.auth.decorators import login_required

def userlogin(request):
    if request.method == "POST":
        fm = AuthenticationForm(request=request, data=request.POST)
        if fm.is_valid():
            username = fm.cleaned_data.get('username')
            password = fm.cleaned_data.get('password')
            user = authenticate(request,username=username, password=password)
            if user is not None:
                login(request, user)
                return redirect('/jobseekersprofile/')
        fm = AuthenticationForm()
    return render(request, 'jobglobel/userlogin.html', {'form': fm})```

As described in your other thread, the issue here is not this code. The root problem is that you are not properly creating users, and so the authentication fails.

(Also, please do not spam this site with repeated requests for the same information. Your other thread is sufficient for this topic.)

i do not want to spam i thought i will get replies for my problem, i did not got much answers from people, and question was gone also too much down on the main page, so i did post again for issue, btw thanx for the help, i tried different way to register user by inheriting Usercreationform in and rendered it as a registration page, but for that it was asking me for USERNAME_FIELD so i create custom user model, but still facing same problem, now in previous problem i was able to do login in admin site, but after creating custom user i am not able to do login even in admin site, if you want to see code, i can do post.