Skip to content

Instantly share code, notes, and snippets.

@okanyenigun
Created March 1, 2022 12:55
Show Gist options
  • Save okanyenigun/b552df6e749b0cc74558ed187f2a8961 to your computer and use it in GitHub Desktop.
Save okanyenigun/b552df6e749b0cc74558ed187f2a8961 to your computer and use it in GitHub Desktop.
django-login-html
{% extends 'base.html' %}
{% load static %}
{% block content %}
{% load crispy_forms_tags %}
<link rel="stylesheet" href="{% static 'css/login.css' %}">
<div class="main">
<input type="checkbox" id="chk" aria-hidden="true">
<div class="signup">
<form method="POST">{% csrf_token %}
<label for="chk" aria-hidden="true">Sign up</label>
{{form.username}}
{{form.email}}
{{form.first_name}}
{{form.last_name}}
{{form.groups}}
{{form.password1}}
{{form.password2}}
<button name="sign-up">Sign up</button>
</form>
</div>
<div class="login">
<form method="GET">
<label for="chk" aria-hidden="true">Login</label>
<input type="text" name="username" placeholder="Username" required="">
<input type="password" name="pswd" placeholder="Password" required="">
<button name="sign-in">Login</button>
</form>
</div>
</div>
<!-- This template is copied from -> https://codepen.io/mamislimen/pen/jOwwLvy -->
{% endblock %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment