Django port changing [closed]

十年热恋 提交于 2019-12-25 18:35:27

问题


I've started Django server on localhost:8000 and everything wold be okay, but after clicking on different tabs it changes port to localhost:8002/othertab, how can I set 8000 for default port?


回答1:


If you want to change the server’s IP, pass it along with the port. So to listen on all public IPs (useful if you want to show off your work on other computers), use:

 $python manage.py runserver 127.0.0.1:8002

For more details click here .



来源:https://stackoverflow.com/questions/23359389/django-port-changing

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!