Accessing a database

When working with databases, today's application servers have the ability to connect in a simple way by configuring data sources. For example, our application could use an application server to serve pages dynamically by querying a database to obtain or modify data, and display them later in an HTML page using asynchronous server queries.

The use of a database to store content allows you to separate the design of the website from the content that you want to show to the users of the site. Instead of writing individual HTML files for each page, you only need to write a page or template so that you can present the data in the database to the user. You can also dynamically submit HTML forms that add or modify information in the database. 

In the following diagram, we can see a schema for processing a request in a web and database server:

In the previous diagram, we can see how the client makes a request to the application server, connects to the database to perform the query through database driver, and when the query result returns to the application server, the response object is returned to the client browser.

In next section, we are going to review Django and study some commands to introduce this framework and its powerful administration panel.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset