How can i Add captcha to my Html form using Django - django

I have already made a website with Django but unable to add captcha with Django and link it with html template

As the others stated, I don't know what you tried so far, but there are some packages already implemented for a captcha with django.
Follow the link below and choose a package which suits your needs. If there's a problem with one of the packages you can't solve after you read the documentation, you can come back here and ask again.
Django captcha packages.

Related

Designing Django admin panel by tailwind

I hope you are fine.
I want to customize my django admin panel by tailwind. I know how to use tailwind in the templates of my django apps but unfortunately I am not able to use tailwind in the admin template and I have also tried multiple ways to solve this such as putting cdn in the admin base.hml or installing django-tailwind but all of them hasn’t worked for me yet.
I will thank if anyone who has experience about this matter give me a piece of guidance.
The django-tailwind package is not for django admin customisation. The first step could be this package django-admin-tailwind from here, you can add some more code to the package to suit your needs, probably make a PR as well. Happy coding!

django blog zinnia Template Customizing

I was wondering what is the best way for customizing zinnia because by default when installing via pip it installs in site packages do I need to open the site package directory and edit it from there? Just want to know. Plus do I need to do some extreme tweaking to zinnia in other for it to work since all I want is a simple post that, displays entries as a list and detail or I just leave it as it is after installation.
As written in the comments, you need to create the static dir and collect the templates.
The best place to look and get an explanation is the Django documentation. Here is the link to the deployment section. Please make sure you read the other sections as well: https://docs.djangoproject.com/en/1.11/howto/static-files/#deployment

Django Image Upload

I am trying to upload an image using a form with Django. First off, I don't know if I should be doing this with django or a combination of jQuery and Django. Second, I am looking for a simple tutorial using 1.7 and can't seem to find one. Is there something like this for version 1.7. I'm just looking for something super simple and then I can expand from there.
Code from your link should work perfectly in django 1.7.
The linked tutorial will work for Django 1.7, along with pretty much any tutorial. The one thing you're going to run into that's different in 1.7 is that the migrations are built into Django now instead of using a 3rd Party App called South.
You definitely should be using django forms to upload the image, it's really simple once you get the hang of it - it's just like another field. You definitely should not use a combination of JQuery and Django.
If Django can't do what you're wanting to accomplish, take a look at Django Crispy Forms. I would suggest getting an understanding of just using Django image uploading first through, regardless.
Hope this helps. Also take a look at the Official Documentation of file uploads, if you haven't already.

django admin django.contrib.staticfiles

I'm following the tutorial contained here:
http://www.djangobook.com/en/2.0/chapter06.html
They say that the admin site should look like this:
http://www.djangobook.com/en/2.0/_images/admin_index.png
When I start the admin site, though, it looks really simplistic, just plain text and links:
Django administration
Welcome, admin. Change password / Log out
Site administration
Auth
Groups Add Change
Users Add Change
Recent Actions
My Actions
None available
I noticed that it looks all nice like the link when I uncomment django.contrib.staticfiles from the INSTALLED_APPS, although that wasn't mentioned in the tutorial...can someone please explain this behavior to me?
Thank you for your help!
The Django Book is a little out of date (although an update is in the works I believe):
This book was originally published by Apress in 2009, and covered Django 1.0. Since then, it’s languished. We’re working on getting the book updated to cover Django 1.4, 1.5, and beyond
Static files are all the CSS/JS & images that your site (and the django admin) uses. They need to be collected and placed somewhere that your server (or development server) can serve them. This is the job of django.contib.staticfiles.
You can read more about this in the 'Managing Static Files' documentation
Websites generally need to serve additional files such as images, JavaScript, or CSS. In Django, we refer to these files as “static files”. Django provides django.contrib.staticfiles to help you manage them.

django social auth integrate "register with email"

I am using django social auth in my project and wanted to add email registration on my website as well. I can think of hacking it in since I have played with DSA quite a bit now, but this seemed like a pretty standard problem people using DSA would run into. Is there a elegant way to do this integration?
UPDATE:
One of the major reason I am asking is, I dont want to use another django plugin only to find out later that it doesnt play well with DSA. Would appreciate if someone who has got this to work could share.
I've been using social_auth successfully with django-registration in one project. Registration with Facebook/Google works well, also email registration works as expected.
Django-registration had some issues with Django 1.5, but I believe they are fixed. I'm just updating this project from Django 1.4 to 1.5 so hopefully I can confirm this in a week or so.