AZ
Please dont send DMs without asking for permission
Anonymous
Ok guys how much day it take learn DRF
Charly
Ok guys how much day it take learn DRF
Depends on a lot of factors, between a couple weeks and some months
Charly
Months??😂😂
Yes, there are a lot of factors
@
Yes, there are a lot of factors
But if you already know django well, it should take a few days or weeks at most
Charly
But if you already know django well, it should take a few days or weeks at most
Yes, in most cases, bu he didin't even knew what was REST
Anonymous
Yes, in most cases, bu he didin't even knew what was REST
Yes i don't know rest It's bit like confusing
Sayidbek
Is heroku still free for hosting Django
Anonymous
Dmitriy
Hosting multiple sites on a single VPS. Using docker network. I use acme to get certs, it seems that I managed to get them, but cannot bind them to my url. Any suggestions? Docker volume inspect shows this: "CreatedAt": "2022-10-14T10:06:08+03:00", "Driver": "local", "Labels": { "com.docker.compose.project": "adventures", "com.docker.compose.version": "1.25.0", "com.docker.compose.volume": "certs" }, "Mountpoint": "/var/lib/docker/volumes/adventures_certs/_data", "Name": "adventures_certs", "Options": null, "Scope": "local" }
Sandeep
How to load templates in django? Please let me know
𝕯aniel
How to load templates in django? Please let me know
Copy Files to static folder Copy Html pages to templates folder After do load static in html page Example: {% load static %} <link rel="stylesheet" href="{% static 'polls/style.css' %}">
𝕯aniel
And do not forget create base.html page where you load only website navigation and footer
𝕯aniel
After you need include it to all new page via {% extends 'base_html_file_path' %}
Adrian
Aldo you need to configure your template's path in the settings' file
Jasurbek
I am testing my django project in a server with postman. If I send a request without body it returns the correct error message. But if I send a request with body it is showing 404 error by saying 'Page not found' What can i do
Sarvar
NO i said drf community where is it
▄︻デռǟɦօʍ══━一
how to add a button that executes a function but not a url
Anonymous
How to disable csrf token for some view functions? @csrf_extempt method works on localhost but when I host it on pythonanywhere then it starts giving csrf token missing error.
▄︻デռǟɦօʍ══━一
▄︻デռǟɦօʍ══━一
Maybe using Ajax?
it uses url but i dnot want
Marc
I want to put 4 items in a row. Getting following error: Could not parse the remainder: '|' from '|' without the if loop code works fine https://linkode.org/#4cfKuYpbSWxFdI9tIWQSY5
Harshavardhan Reddy
Hello guys, is any one know how to integrate voice support  and chat bot for django project
Marc
Hello guys, is any one know how to integrate voice support  and chat bot for django project
here is a tutorial https://studygyaan.com/python/create-web-based-chatbot-in-python-django-flask also https://search.brave.com/search?q=django+chatbot
Cheshtaaaaaaa
What's the use of elephant SQL
Doragonsureiyā
What's the use of elephant SQL
These single steps will help you a lot: Step 1️⃣: Open a browser Step 2️⃣: Write down https://google.com or https://duck.com and press Enter Step 3️⃣: In the search box, write down the same words you asked here Step 4️⃣: Read the first results
Hemant
I am doing an assignment where I am supposed to customize admin view to add a list of apps with some basic attributes like app name, app link, icon, etc. When I am trying to make group of two fields (say: app name and app link) by inheriting admin.ModelAdmin I am getting below error: TypeError: __init__() missing 2 required positional arguments: 'model' and 'admin_site' Here is the code. I tried running it in Python 3.7 and 3.10.x both and just the difference is 3.10.x specify ModelAdmin.__init__() in error message and 3.7 doesn't. edit: Solved solution: I was actually overriding the default admin but I should have revert my previous changes to bring back django.contrib.admin in settings.py
mohamed
Hello I’m trying to load css file and I used load static but still not working
navid
can i have a look at ur files
navid
STATIC_URL = "static" STATICFILES_DIRS = [os.path.join"BASE_DIR", "static"]
navid
add this to your settings.py
navid
Which file
the files structure i mean make the static folder near the apps folders
mohamed
I’m using bootstrap
Bhaghi
give the link in ur html
navid
set the href of ur style sheet link like so: "{% static '/base.css' %}"
𝙑𝙞𝙯 𝙋𝙖𝙡𝙖𝙨
navid
I did that too
hold shift and press f5 on your browser it forces static files to load
mohamed
Thank you so much guys
navid
happens a lot actually remember the shortcut
SumithVarma
Hello all Can any one help me with error unexpected tokens at <!DOCTYPE html> after loading static file
Sravya
<ul class="errorlist"><li>date_joined<ul class="errorlist"><li>This field is required.</li></ul></li></ul> bro i am facing this error while registration what can i do for that
Rakesh
Hi all, Anyone know how much space we will have in Django DB (inbuilt database) ? Means how much capacity of data it can store?
navid
but i guess ur not putting the field in ur html in the first place
navid
are u making a form yourself?
navid
or using {{ form.as_p }}
Prog Hisham
Hello there, I want to call the blog variable which is in settings.py inside the change_form.html
Mirco
What 🤯
Yes it is
Marc
Hello there, I want to call the blog variable which is in settings.py inside the change_form.html
use from django.conf import settings then you have access to vars
Prog Hisham
use from django.conf import settings then you have access to vars
I want to access the variable inside a django admin html
Ankiniki
django.template.library.InvalidTemplateLibrary: Invalid template library specified. ImportError raised when trying to load 'rest_framework.templatetags.rest_framework': cannot import name 'FieldDoesNotExist' from 'django.db.models.fields'. Can anyone help me out for above error.
mohamed
How can I make all photos in the web page in same size , I know that relates to CSS but I need help
mohamed
Well, there I think about bootstrap img-fluid class
Thank you it worked but if I add new photo with bigger size , the card becomes bigger than the other ,, I used the card from bootstrap
Prog Hisham
use from django.conf import settings then you have access to vars
It works thanks 😊 after also adding the render in view to the admin html
Ogundare
Hello senior Django devs, is it possible to have multiple apps in a single project, where the first app will be the main domain and other apps will be the subdomain, thereby having the urls.py as, main app(abc.com) other apps (xyz.abc.com, fgh.abc.com) etc. Please, how possible is this?
Mujahed Saleem
you can define them as dict in middleware . When request come you will read domain from it and redirect it to designated app