X

Select Your Country

Turkey (Türkçe)Turkey (Türkçe) Worldwide (English)Worldwide (English)
X

Select Your Currency

Türk Lirası $ US Dollar

Defining Django 2.0 urls.py robot.txt File

Defining Django 2.0 urls.py robot.txt File
HomepageKnowledge BaseGeneralDefining Django 2.0 urls.py robot.t...
Defining Django 2.0 urls.py robot.txt File

To define the robots.txt file in Django 2.0, you can add the following code to the urls.py file.

path('robots.txt', lambda x: HttpResponse("User-Agent: *\nDisallow:", content_type="text/plain")),

Can't find the information you're looking for?

You have examined the knowledge base in detail, but if you cannot find the information you need,

Create a Support Ticket
Did you find it useful?
(418 times viewed. / 1 people found helpful.)