Django -1 installation and setup
Django is a popular Python Web Framework (probably the most).it
is very easy to develop web sites using Django. In this tuition, we are going
to go throw basic steps how to deploy websites using Django.
Installation
Just download the Django package from the
Django official websites:
https://www.djangoproject.com/download/
and untar it. In my case, I downloaded Django-1.5.1.tar.gz.
You will find a file called setup.py. to install the Django, use command
#python
setup.py install
By default, the installation will create a
directory called django under your
Django unzipped directory.
To verify if Django is installed correctly,
you can go into python shell and
>>import django
>>django.VERSION
if you can get the correct output showing
the django version. it indicates the django is installed correctly.
Setup the new project
Go to the directory you want to locate your
project.
Use django-admin.py (which is located in
your previous django/bin directory ) to set up the new project. As
#django-admin.py
startproject testproject
Test the new project
run the command to start up the new project
#python
manage.py runserver [ip:port]
No comments:
Post a Comment