Anonymous
How can I write a messenger using Django?
Doragonsureiyā
How can I write a messenger using Django?
What have you tried to solve this issue?
Anonymous
What have you tried to solve this issue?
I tried to create a form and enter it into the database, but I can’t create personal chats.
Neo
How can I write a messenger using Django?
Look at existing projects and learn from them. Github is your friend
Neo
and please consider using a name on your telegram that is far less annoying.
Pranav
Hi I want to change innerText in div in HTML from the server side Note *-> withOut reloadeing the 📄 page. How I can do that ? If anyBody knows please 🥺 Help me 🙏
Ali
Hi I want to start project about gps tracking service, I.e online taxies. Many vehicles are moving on the map realtime and I want to manage theme show every vehicle info and...
Ali
so?
This is the dashboard for management of online taxies
Ali
And? Do you have a question?
How can I do this? Just for web not mobile. I want to use openlayers and django for backend. But I have problem in openlayers to get data and show motions on the map realtime
Charly
How can I do this? Just for web not mobile. I want to use openlayers and django for backend. But I have problem in openlayers to get data and show motions on the map realtime
So tart reading the Django documentation, the openlayers documentation. Take paper and pencil and design the architecture of your app. If you have a problem with openlayers and it's on the Django side then give details here so we can help you.
Arturito ®
hey community could you help me whit this error : Traceback (most recent call last): File "/home/arturoalvarado/anaconda3/lib/python3.11/site-packages/django/core/handlers/exception.py", line 55, in inner response = get_response(request) ^^^^^^^^^^^^^^^^^^^^^ File "/home/arturoalvarado/anaconda3/lib/python3.11/site-packages/django/core/handlers/base.py", line 204, in _get_response self.check_response(response, callback) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/arturoalvarado/anaconda3/lib/python3.11/site-packages/django/core/handlers/base.py", line 332, in check_response raise ValueError( ^ Exception Type: ValueError at /registro_paciente/registro_de_citas/ Exception Value: The view registro_paciente.views.registro_de_citas didn't return an HttpResponse object. It returned None instead.
Arturito ®
your view somehow doesn't return any response🤔
def registro_de_citas(request): if request.method == 'POST': form = RegistroDosForm(request.POST) if form.is_valid(): form.save() return redirect('registro_paciente/registro_de_citas/') else: form = RegistroDosForm() return render(request,"sistema/registro_de_citas.html",{'form':form})
Arturito ®
my codig is in spanish
Arturito ®
and what if the request's method is GET?
this is the i don't undestand beceause i use post and not get
Arturito ®
I learn django 😅
Arturito ®
if change the url the next error is multivalue key
Arturito ®
MultiValueDictKeyError at /registro_paciente/registro_de_citas/ 'nombre' Request Method: GET Request URL: http://localhost:8000/registro_paciente/registro_de_citas/ Django Version: 4.2.5 Exception Type: MultiValueDictKeyError Exception Value: 'nombre' Exception Location: /home/arturoalvarado/anaconda3/lib/python3.11/site-packages/django/utils/datastructures.py, line 86, in getitem Raised during: registro_paciente.views.registro_de_citas Python Executable: /home/arturoalvarado/anaconda3/bin/python Python Version: 3.11.4
Lightbourne
this is the i don't undestand beceause i use post and not get
then try to remove all of your code from the view and just return HttpResponse 200 to see if your view is configured properly but i'd still suggest you verify that the view works okay for GET as well. make it return "method GET not allowed" or something. or just use class-based views, they handle that under the hood
Arturito ®
the problem seems to be inside of your form
yes but i changed some lines thar i saw in stackover and nothing
Bl@ck
Can anyone help me to connect my html form to js in django
Bl@ck
What is the problem ?
I have made eventhandlers for html forms and loaded static files in html template...is that enough to connect js with django?
Bl@ck
I'm a newbie..
Ali
Yes you can just connect your needed with <script> tag in your Django html. But do this just for now. I recommend to use api to provide data. You should separate frontend and backend in the future.
Muflone
I have made eventhandlers for html forms and loaded static files in html template...is that enough to connect js with django?
Your Js code interacts with Django by doing rest requests using ajax or xmlhttprequest
Maya
Can you help me divide Django and DFR components into MVC components. What is what (model, controller, view)?
Lightbourne
Can you help me divide Django and DFR components into MVC components. What is what (model, controller, view)?
what🤔 django and drf already follow the MVC pattern if you mean to ask the differences about MVC components https://medium.com/shecodeafrica/understanding-the-mvc-pattern-in-django-edda05b9f43f
Lightbourne
wrong, Django doesn't follow MVC patter, it follows Django pattern... —neither DRF does—
it follows MVT, just slightly different naming. and drf keeps the same standard
cj
it follows MVT, just slightly different naming. and drf keeps the same standard
https://docs.djangoproject.com/en/4.2/faq/general/#django-appears-to-be-a-mvc-framework-but-you-call-the-controller-the-view-and-the-view-the-template-how-come-you-don-t-use-the-standard-names > At the end of the day, it comes down to getting stuff done. And, regardless of how things are named, Django gets stuff done in a way that’s most logical to us. so, it's the Django pattern ¯\_(ツ)_/¯ not MVC, not MVT
ashu
Hlo guys can anyone share the process like how we integrate the WhatsApp message api in django with API key only
S
Hi, there is a doubt that while sending push notifications as a task the failing tokens should be removed . there will be a chance to update tokens while uninstalling and reinstalling app. we should find that failing tokens by checking notifications delivered or not. and delete those tokens. is there any method for this process?
Kevin
Hello, help me. When I write my html code in my templates and launch the server it shows me this result and I don't understand why I have this result. Someone to help me?
Kevin
‘’ get/favicon.ico http/1.1’’ 404
Kevin
Ok
bot
Guys how to do addcart
Doragonsureiyā
Guys how to do addcart
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
Ayush
SUGGEST EASY DJANGO PROJECTS...
Mirco
SUGGEST EASY DJANGO PROJECTS...
there's no need to write in uppercase 😊
Doragonsureiyā
SUGGEST EASY DJANGO PROJECTS...
Check out PythonRes, a channel for Python resources - video courses, pdf books, tutorials and other info to help you learn Python.
Heisenberg
How can i implement Crispy forms with Tailwind css?
Jahongir
How can i implement Crispy forms with Tailwind css?
https://www.google.com/search?q=How+can+i+implement+Crispy+forms+with+Tailwind+css%3F&oq=How+can+i+implement+Crispy+forms+with+Tailwind+css%3F&gs_lcrp=EgZjaHJvbWUyBggAEEUYOdIBBzMyMGowajeoAgCwAgA&sourceid=chrome&ie=UTF-8
Артём
Hey 👋 I've never used auth and ref in django with telegram. How do i implement this?
Tejas
Does anyone know why the error "fromisoformat: argument must be str" occurs 🙏🙏please give me some hints.🙏🙏
ashu
Hey guys can anyone review this code
Doragonsureiyā
Hey guys can anyone review this code
Rule 5️⃣: Never post walls of text or screen photos. Use paste bins like https://hastebin.com, https://nekobin.com, https://dpaste.org (or your favorite one)
ashu
Ohk sorry bro
ashu
https://hastebin.com/share/uyujodeber.python
ashu
I want this code to when user fill a form then after they got a thank you mail i am using sendgrid api
ashu
I don't where I am doing mistake
ashu
No but the mail is not send
Jitxs
is "corsheaders" safe to use in django project or do we have alternative or some different methods ?
Anonymous
Levying and anticipating projects in django anybody can tell how to work on it
jobless
Guys , my static files are not linking with my template/html files and I tried everything shown on YouTube and nothing is working out. Do you guys have any idea about it.
Anonymous
Anybody tell how to create login and register page in django with database mysql
Charly
Anybody tell how to create login and register page in django with database mysql
Please first complete the official tutorial to know how Django works
Doragonsureiyā
Where will I learn
Looking for Django tutorials? you can follow these three recommended ones: * Official documentation and tutorial * Tutorial from MDN * Tutorial from django-girls
Anonymous
Hey,I am created new project with the virtualenv after that i am moved that project to another location now i am not able to use pip freeze to know what are the dependences installed, but env is working fine .How to know the installed dependences versions Thanks in advance