shared a local host django 1

shared a local host django

1. run python runserver
2. figure out your ip address which is say
3. Add '' to ALLOWED_HOSTS list in your file.
4. access on mobile.

Here is what the above code is Doing:
1. We are importing the HttpResponse class from the django.http module.
2. We are defining a function called index which takes request as its parameter.
3. We are returning an HttpResponse object that has “Hello, world. You’re at the polls index.” as its content.

Similar Posts