摘要: Form 表单 示例程序: 1. 创建表单类 2. view CSRF 1. 普通表单,通过表单的方式将token再次发送到服务端 2. Ajax view.py text.html 阅读全文
posted @ 2016-10-14 23:44 garyyang 阅读(143) 评论(0) 推荐(0)
摘要: Model 创建表 from django.db import models class userinfo(models.Model): name = models.CharField(max_length=30) email = models.EmailField() memo = models. 阅读全文
posted @ 2016-09-24 01:10 garyyang 阅读(160) 评论(0) 推荐(0)
摘要: Django 基本操作 Django 处理请求流程 Views and URLconfs To design URLs for an application, you create a Python module called a URLconf. Like a table of contents 阅读全文
posted @ 2016-09-10 01:59 garyyang 阅读(210) 评论(0) 推荐(0)
摘要: Django 基本操作 Django 处理请求流程 Views and URLconfs To design URLs for an application, you create a Python module called a URLconf. Like a table of contents 阅读全文
posted @ 2016-09-02 20:45 garyyang 阅读(170) 评论(0) 推荐(0)
摘要: jQuery jQuery 是一个轻量的 JavaScript 库, jQuery 包含了以下特性: HTML/DOM manipulation CSS manipulation HTML event methods Effects and animations AJAX Utilities HTM 阅读全文
posted @ 2016-08-27 11:27 garyyang 阅读(138) 评论(0) 推荐(0)
摘要: HTML 元素分类 块级元素 (Block-level element) 块级元素就是以块显示的元素,高度宽度可以设置。包含以下几种: 结构化块级元素: <ol> <ul> <dl> <table> 终端级块级元素: <h1>...<h6> <p> <dt> 多目标块级元素: 所谓多目标指的是可以自 阅读全文
posted @ 2016-08-20 01:14 garyyang 阅读(114) 评论(0) 推荐(0)
摘要: HTML HTML 基本结构 基本标签 段落 List Table 表单 css 选择器 html 标记选择器 class 选择器 /*class 选择, 找到c1的标签*/ .c1{ background-color: red; } id 选择器 /*id 选择, 找到id 等于i1的标签*/ # 阅读全文
posted @ 2016-08-13 00:55 garyyang 阅读(173) 评论(0) 推荐(0)
摘要: SQLAlchemy - Object-Relational Mapper First create Base class: declarative_base is a factory function, that returns a base class (actually a metaclass 阅读全文
posted @ 2016-08-05 20:18 garyyang 阅读(173) 评论(0) 推荐(0)
摘要: Rabbitmq Hello World! sending: 1) establish connection 2) create a queue to which the message will be delivered In RabbitMQ a message can never be sen 阅读全文
posted @ 2016-07-26 01:34 garyyang 阅读(177) 评论(0) 推荐(0)
摘要: Python 多线程 在Python中我们主要是通过thread和 threading这两个模块来实现的,其中Python的threading模块是对thread做了一些包装的,可以更加方便的被使用,所以我们使用 threading模块实现多线程编程。 threading模块 Thread 线程类, 阅读全文
posted @ 2016-07-23 00:56 garyyang 阅读(173) 评论(0) 推荐(0)