Professional Documents
Culture Documents
Position Pa Permit Spec 2 Django
Position Pa Permit Spec 2 Django
Web Frameworks is a type of software framework that takes us away from the usual structured
programming that developers know of. It is designed to support the development of dynamic websites,
web applications, web services and resources. They already have libraries for the database use, session
management and promote code reuse. Designing a website with the help of a web framework employs
the model-view-controller or a three-tier organization to which applications are structured around three
physical tiers: the client, application and database. The database is normally the RDBMS, the application
layer contains the logic of the application running on the server while the client runs the HTML generated
by the application layer.
There are a number of web application frameworks available for development of projects, each
web application framework rooted from a popular web programming language. For example: In PHP, you
can basically talk about Joomla or Code Igniter, Python also has several other frameworks written under
it, the one that this position paper will be concentrating on is Django.
Djangoproject.com defines Django as a high level Python web framework that encourages rapid
development and clean pragmatic design.
History
Django was conceptualized in 2003 when the web programmers Adrian Holovaty and Simon
Willison used Python to build applications. Released publicly in 2005, the framework was named after
guitarist Django Reinhardt. In 2008, it was announced that then newly founded Django Software
Foundation will maintain the Django Framework.
Django already has this in place and has many essential pieces of code for a developer built on its
libraries.
Features of the Django Framework
Object-relational mapper
You can define your data models purely in Python but still write SQL as needed.
Cache system
Django employs a cache system for super performance
Internationalization
The programming language has support for multi-language applications. Django lets you
specify translation strings for any programming language to hook up with your
application instantly.
With Django being a Python web framework, Django requires Python, it works with
version such as Python 2.7, 3.2 and 3.3
Apache and mod_wsgi is only needed if you install Django in a production setup, if you are just going to experiment, Django already has a web server in place.
If for some reason you cannot use mod_wsgi, there are other deployment options
such as uWSGI which is supported by nginx.
SQL Lite is generally the simplest version to work with on a Django project, for
an experimental testing like Django. However if you are working on something
that is substantial especially when you move to production, better start working
with those databases such as Oracle or PostgreSQL.
Get to install the Python data bindings depending on the backend installed.
Install pip. The easiest is to use the standalone pip installer. If your
distribution already has pip installed, you might need to update it if its
outdated. (If its outdated, youll know because installation wont work.)
If youre using Linux, Mac OS X or some other flavor of Unix, enter the
command sudo pip install Django at the shell prompt. If youre using
Windows, start a command shell with administrator privileges and run
the command pip install Django. This will install Django in your Python
installations site-packages directory.
It has good documentation originating from Python, Django is known to have a wellwritten documentation, there is a saying that goes that if it is not well implemented, it is
not documented.
Template System the template system of Django has been the inspiration of other
programming languages.
Licenses Django is under the BSD Software Distribution while the older ones are under
GPL making it easier to distribute the software.
Open Community Problems will not be away in any development measure, there is an
open community for Django to which developers can share their ideas with.
In a web application framework, what is commonly measured is the performance of the framework,
Django has tools which can be able to answer performance measures to which a developer can check how
his application is doing:
Django Toolbar
o
Profiling Middleware
Load Testing
o
Load testing can easily generate HTTP traffic in volume, sending a decent
number of concurrent requests against your application and returning some useful
results.
Djangos security measures changes the way web development is done. A developer should never trust
the user and never trust the data, no exceptions. A developer must look at the layer to which security may
be compromised:
User Management
Authorization
Cookies
SQL Injection
Clickjacking
o
Django protects against clickjacking which is the act when a malicious site tricks
a user into clicking on a concealed element of another site which they have
loaded in a hidden frame or iframe.
Directory Traversal
o
You cannot easily access the root directory or a user account will not be given
access to the root directory.
With these measures, developers may choose to use Django than other frameworks to make sure that their
applications are available 24/7.
Django in the Philippines
When you talk about web development in the Philippines, the first thing that would come to mind
is PHP or the CMS packages such as Code Igniter or Drupal, only a handful of developers start with
Python more so Django.
Django should be applied in the Philippines for the reason that it is a secure framework something
that web developers in general have left out especially in the government where every now and then
websites are hacked. If you are going to look at the websites that use Django: Pininterest and Instagram
for example, it is not that vulnerable to security loopholes to which websites in the government had been
subject to. WebCube (2012) describe Django as the global platform as it can be considered as scalable
which Pininterest and Instagram has proven.
There is already a case study that shows why Django in form of security extensibility which is
somehow neglected by developers. If you look at the deployment or the coding scheme, since it was made
in a newsroom where deadlines have been evident, Django is an ideal way of creating web projects easily.
Django can be an effective framework for government websites which actually show the risk of
being hacked nowadays. If you would look at the system, it can be easily seen when you view the source
of the project and Django means to change that idea.
If you are not really used to hard coding Django as it is which is a structured programming
language used to implement websites, There is also a Content Management System powered by Django.
DjangoCMS.org is a website that caters to web developers who would like to use Django as their CMS.
Orange Communications (2012) cites the need to create their website to change their old website
to which their users have a hard time navigating through their site to find the information they required.
They also feel they lost their appeal to the market with their old architecture with them pulling away
from the B2C and B2B.
What they wanted to see was their users finding the information they want, check out if their
customers are buying their products or to check if they could easily support their users. They had
achieved the result they want through this:
A better design with a three-click rule that is found within the website.
If developers can take time to use Django instead of having to go through the usual HTML or other
structured programming languages, it can be assured that there would be continuous service, easier
deployment and fast-paced integration to users.
The proponent of this position paper hopes that people take time to learn Python more so, Django and
improve their web programming skills.