Title

Monday, 19 January 2015

Not able to install Django on windows 7


I am trying to install Django-1.5.5 on windows 7. I have installed it but when I try to punch in "django-admin.py startproject mysite" I get following error:

C:\Users\DIPANSHU>django-admin.py startproject mysite  Traceback (most recent call last):   File "C:\Django-1.5.5\django\bin\django-admin.py", line 2, in <module>   from django.core import management   File "C:\Python27\lib\site-packages\django\core\management\__init__.py",  9, in <module>   from django.core.management.base import BaseCommand, CommandError, han  fault_options   File "C:\Python27\lib\site-packages\django\core\management\base.py", lin  in <module>   from django.utils.encoding import force_str   File "C:\Python27\lib\site-packages\django\utils\encoding.py", line 10,  dule>   from urllib import quote   File "C:\Python27\lib\urllib.py", line 26, in <module>   import socket   File "C:\Python27\lib\socket.py", line 47, in <module>   import _socket  ImportError: DLL load failed: The specified procedure could not be found.

Previously, I tried with Django-1.4.2 but problem was same. I am having Python27.Please assist.

Answer

I would make sure that DJango is installed by running

python -c "import django; print(django.get_version())"

https://docs.djangoproject.com/en/1.6/intro/tutorial01/

I found the Django tutorial on their site to be very good

Also what exactly are you typing into the command prompt ? You should simply be in directory C:\Users\DIPANSHU> in the command shell

EDIT: you should be in the directory where you installed Django

No comments:

Post a Comment