Forwarded from Библиотека Питониста
Build a Website with Django 3 by Nigel George (z-lib.org).pdf
13.7 MB
Build a Website With Django 3 - 2019
#django
#django
👍1
Django da qanday qilib userlarning IP Address larini aniqlab ,ularning GeoLocationini topishni urganmoqchi bulganlar uchun juda yaxshi maqola ⚡️⚡️🥳
https://medium.com/@arrosid/get-visitor-location-using-geoip2-in-django-32ad3d417115
https://medium.com/@arrosid/get-visitor-location-using-geoip2-in-django-32ad3d417115
Medium
Get Visitor Location using GeoIP2 in Django
In this story, I will show you how to get Visitor location based on visitor IP Address
👏5🔥1
For CSRF Problems in Django >= 4.0
Solutions
1. Above Image ->
3. Corsheaders ->
*
Solutions
1. Above Image ->
CSRF_TRUSTED_ORIGINS = [
'https://subdomain.example.com',
'https://*.blob.com',
...
]
2. Please put -> {% csrf_token %}
inside <form> tag.3. Corsheaders ->
*
pip install django-cors-headers
* add 'corsheaders' in installed apps
4. Use decorators for view functions -> from django.views.decorators.csrf import csrf_exempt, csrf_protect
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
🐳7
Please open Telegram to view this post
VIEW IN TELEGRAM
Tuts-Station
Django - Tuts-Station.com
Django,Python
👍2😍1
drf-yasg da Project Api[Docker da qilinayotgan] sining docs(swagger) ni qilayotganda shunaqangi 👆 muammolar chiqsa agar docker container ni rebuild qilish kerak.
docker compose build
and docker compose up
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM