python's Django framework (server and application, basic three-piece suite and related configuration)

Chapter 12 Django Framework 12.1 Server applications and Applications The server program is responsible for encapsulating the socket server and sorting out all kinds of data requested when the request arrives. The application is responsible for specific logical processing. In order to facilitate the development of applications, there are many ...

Posted by ftrudeau on Thu, 22 Aug 2019 16:44:11 +0200

session and cookie,django Middleware

0819 self-summary session and cookie 1.django sets session request.session['name'] = username request.session['age'] = 13 A session ID of key: {"name":'username','age': 12} is automatically generated and encrypted in the latter part of django. 2. Get session request.session.get('name') 3. Five session settings in Django 1. Datab ...

Posted by toledojimenez on Mon, 19 Aug 2019 13:44:50 +0200

Chapter 3 Article Management and Display

Article Directory 3.1. Manage Article Items 3.1.1 Setup Columns There must be content in the website. At present, there are two kinds of content that can be classified according to the way content is generated. One is "User Generated Conte ...

Posted by vtroubled on Sat, 17 Aug 2019 08:03:03 +0200

django logon authentication for 8 users from scratch to be tested

Look at the document djang with a user login verification method, but some look at the foolish, go to the Internet to find a circle, found that many are copying the document description, hardly say what the principle is.   In particular, from django.contrib.auth import authenticate It's said that this is the way, but it seems that the d ...

Posted by vwinstead on Wed, 07 Aug 2019 11:06:26 +0200

Introduction of python's Djiango framework

I. Essence of Web Framework All Web applications are essentially a socket server, and the user's browser is a socket client.   Return different contents according to different paths You can write several simple pages and then access the corresponding page test by http://127.0.0.1:8080/page name import socket server = socket.socket() ...

Posted by prcollin on Wed, 07 Aug 2019 08:47:49 +0200

Use of cookies and session s in Django

Use of cookies and session s in Django http protocol Two features: No connection: disconnect in one response to a request. Stateless: Do not remember the last connection information, each connection is a new connection. Later: keep-alive cookie: session tracking (resolving http protocol stateless) what: Browser technology. Standard: ...

Posted by lingo5 on Tue, 30 Jul 2019 21:02:12 +0200

Django Builds Shops and Commodities on E-commerce Websites Shop Verification and Up-and-Down Destruction of Commodities

Follow up on the previous blog: Django Builds Stores and Commodities on E-commerce Websites Store Registration and Commodity Management (2) 1. Adding check-ups to check whether users have shop functions 1. Check the store's cookie when the user logs in Verify that the user owns the store after the log ...

Posted by robos99 on Sat, 27 Jul 2019 10:19:34 +0200

Django-ORM table building

Foreplay ORM (Object Relational Mapping) is a technology to solve the mismatch between object-oriented and relational database. Advantages of ORM: The main problem that ORM solves is the mapping of objects and relationships. It usually corresponds one class to one table, each instance of a class corresponds to a record in the table, and each ...

Posted by jagat21 on Sat, 20 Jul 2019 07:40:52 +0200

Django and xadmin build backstage management system-django development environment

Learning environment: redhat 5.8 python version: 3.6.8 django version: 1.11.20 1.python environment installation First, open the following official web site to download the source installation package directly:https://www.python.org/ftp/python/3.6.8/Python-3.6.8.tar.xz After downloading, upload it to the linux environment and extra ...

Posted by fabrice on Fri, 19 Jul 2019 12:32:48 +0200

DjangoRestFramework series: Serialization: Formatting python objects into json

Tutorial 1: Serialization introduction This tutorial will show you how to create simple Web API (restful) code with good cohesion. In the process, it will introduce the various components that make up the REST framework and give you a comprehensive understanding of how everything comes together. E ...

Posted by hezll on Fri, 19 Jul 2019 11:34:32 +0200