Adam
If you are on the same domain, session auth is enough and the easiest If you plan to move to different domains then it makes to start with JWT already
I already have JWT authentication implemented. But I can't decide which approach I should use to work with tokens
Mirco
Srishti
Is there anyone who has worked on Zulip code
Doragonsureiyā
Is there anyone who has worked on Zulip code
Don't ask meta questions like: "Any user of $x here?" "Anyone used technology $y?" "Hello, I need help on $z!" Just ask directly! The better you are at explaining the problem, the more likely you are to get help. Asking smart questions
Zakir
Can anyone explain me how to solve this -"MultiValueDictKeyError"
Zakir
Please
Sunny
Can anyone explain me how to solve this -"MultiValueDictKeyError"
Try using .get() method to get data from dictionary
Vaibhav
Noddy
I declared auth class in views as per requirement
Faraz
Hello Everyone: How to do SEO of a Django Project?
Noddy
Hello Everyone: How to do SEO of a Django Project?
Multimillion companies are still struggling to crack perfect seo
Faraz
I have a site build on Django Framework so I want Google to know it.
Azizbek Xushnazarov
I see caching the response is only way to save ur system
Caching is not a solution in our case since every response is unique
Dark
Does anyone know about dask? I want to insert an csv file in dask in batches. So my question is how to determine like dask.dataframe wrok to use or dasks futures?
M. Hossein
I am using djangorestfrework_simplejwt. I know I'll have "get an access token" and "refresh token" endpoints. What other endpoints do I need to make it a full authentication system?
Tamerlan
hello who know tutorial about how use pgvector in django
Srishti
Is that related to django?
It's related to frontend JavaScript
M R. WICK
It's related to frontend JavaScript
You are talking about zulip API?
Maxim
It's related to frontend JavaScript
this is the Django group only questions related to Django topics are accepted
Anonymous
I started Django recently so can anybody help me? How to create product search features on an E-commerce website?
Maleficent
Create a search function in views
Toto Syrax
Is that possible to be a fulltime freelancer? On Django with react
M R. WICK
Yes...
I know i think
Maxim
I know i think
don't answer "who" questions, only topic-specific questions
Pranjal
When I open django server from vs code then my urls are not running over it but when I run from command prompt then urls are run why?
Anonymous
Hi I am working on a drf project and faced an usecase that i don't know what is the best practice.. I am using a token based authentication in my project (simple jwt) and i want to set the token as httponly cookie instead of return in response.. I do that with override a method from simple jwt library.. Also there are some apis that only authenticated users have access to. So in this case the token should be sent in the header (this is the point that confused me) Should i get the token from the header (this is the default) Or override the corresponding method and read the token from the cookie ?? Thanks in advance.
Andrew
Hi I just need to integrate my django into react how this could be done
Andrew
Django rest framework
Yes I have made my project with django rest framework & now I want to connect it with react so please give a simple example
Christian
Yes I have made my project with django rest framework & now I want to connect it with react so please give a simple example
You should make calls to the api through any http library in JavaScript like fetch or axios, there are many examples in google. It’s a basic approach, so it’s easy to find tutorials.
Raj
Hello everyone, I'm currently facing an issue while trying to implement a cross-database ForeignKey relationship in Django. I have two databases, 'orders' and 'users'. The 'Order' model is located in the 'orders', and I want to add a ForeignKey field to the 'User' model located in the 'users' db. I've tried using a custom database router, but I keep encountering errors like "relation 'django_content_type' does not exist." Could someone please guide me on the correct approach to achieve this cross-database relationship? Is there a better way to handle this situation to avoid errors and ensure referential integrity? Here is my approach: https://dpaste.org/rGar0
Ganesh R
To fetch n show 1L rows, what is best way in django 3? Please suggest best ways with reference
M. Hossein
How to import models from other apps without being dependent to that app?
Patrick
you can always do: from app_name.models import model_name
M. Hossein
you can always do: from app_name.models import model_name
Imagine I have model A in app a. I want to import model B from app b. If I follow your approach app a will be dependent to app b which is not a good approach.
Patrick
Imagine I have model A in app a. I want to import model B from app b. If I follow your approach app a will be dependent to app b which is not a good approach.
You can anyway call both models... I don't know if the approach is good or not I have user in user app I have product in products app I call both models to create order data in 3rd app payments
Thainan
hi peoples, how are you? i am brazilian, sorry my writing, some phrases will be translate. I am have difficulty for check password with bcrypt.. My code for check it is: if len(emailExist) == 1: usuario = Usuario.objects.get(email=email) isvalid = bcrypt.hashpw(password.encode('utf8'), usuario.password.encode('utf8')) print(isvalid) in terminal return it is error: Exception Type: ValueError Exception Value: Invalid salt somebody for help?
Thainan
Why are you doing thatmanually when django can handle it itself?
I used to do it like this in javascript programming language, i came to python less than 15 days ago... I'm still practicing rsrsrs... how django does it? some website with examples or url of documention?
Thainan
in a search, i found django.contrin.auth.models... i will test. Thanks guys
Sahil
How to do automatic notification in django rest framework
Nik
hi guys, help me plz. The problem is that the normal language switching does not work when prefix_default_language is set to False, it is necessary that when the prefix is ​​disabled (prefix_default_language=False) the language is automatically switched relative to the browser language. If you leave the prefix, then everything switches perfectly. I am using django-modeltranslation. Help... https://dpaste.org/D8pKN#L4
$--Avadh--$
How to add custom date filter in django admin panel?
$--Avadh--$
From date user created date and to date user modified date
S
Hi, Can anyone guide me. I want to learn django advanced concepts. what are concepts that are comes under advanced and any reference?
Doragonsureiyā
Hi, Can anyone guide me. I want to learn django advanced concepts. what are concepts that are comes under advanced and any reference?
Looking for Django tutorials? you can follow these three recommended ones: * Official documentation and tutorial * Tutorial from MDN * Tutorial from django-girls
Aaroo
https://linkode.org/#pV2sz5NPomP4NbglXiTnC7
Aaroo
https://linkode.org/#pV2sz5NPomP4NbglXiTnC7
I can't fix this program help me
Doragonsureiyā
I can't fix this program help me
Impossible to help without details.
Maleficent
What's your issue?
machindra
Is there anyone who can support me to set up a backend for my django project
vaseem cholakkan
how to push a data to a socket when a signal is triggered ?? anyone ..
vaseem cholakkan
anyone know i have a signal that get fired when a cerian model is saved ( post_save ) and in that signal i need to send a message to frontend through channels like notification,hiw can i achieve that ?
Muhammed
How can I store phone numbers
Muhammed
In models
Jahongir
How can I store phone numbers
you can use django-phonenumber-field
Ajn
Hi, I'm facing an issue with my django project. I migrated from django 3.0.6 to 4.2.3 and now I'm having this 403 CSRF token issue. I did refer the docs and videos and I did the appropriate measures to accompany this new change. Even after giving the csrf token I get a 200 success code, But Im not a getting the api response, instead I see the django admin template. What could have gone wrong?
Sarthak
Hello guys! I'm trying to perform crud operations and not able to do them as my update functionality is not working.
Sarthak
def update_survey(request, id): survey_fetch = survey.objects.get(pk=id) survey_form = surveyForm(request.POST or None, instance=survey_fetch) if survey_form.is_valid(): survey_form.save() return redirect("read_survey") survey_table_data = survey.objects.filter(created_by=request.user).values() context = {"survey_form": survey_form, "survey_table_data": survey_table_data} return render(request, "survey/manage_survey.html", context) #This is my code.
AZ
I finish my website backend with Django and front end with vuejs i want to send verification email for the user email can any one help me with that?
Rahul
You are using Django v4.0 > Try this in your settings.py: CSRF_TRUSTED_ORIGINS = ['https://yourdomain.com']
But this did not help me. But my concern is why the django admin template keeps showing up when I'm making the api call
Тимофей
nginx_1 | 2023/07/29 14:40:35 [emerg] 1#1: host not found in upstream "web:8000" in /etc/nginx/conf.d/nginx.conf:2 nginx_1 | nginx: [emerg] host not found in upstream "web:8000" in /etc/nginx/conf.d/nginx.conf:2 I'm sorry for my English. Hello everyone, I ran into such a problem when working with docker+django. Google for the fourth day, nothing helps. Who can help? I will send all the sources to the personal account. I can even pay a little, but not much, because a student (
Тимофей
Muflone
Does it matter?
Sure it does
Muflone
Does it matter?
so what is the answer?