web_api所需包
摘要:zope.sqlalchemy==1.1 ImportError: Unable to find zbar shared library sudo apt-get install zbar-tools ModuleNotFoundError: No module named '_sqlite3' 安
阅读全文
js模拟表单提交
摘要:1. var data = {"id_ai":id_ai, "info_type":type, "a":Math.random()} var form = $('<form />', {action : "ajax_get_product_detail", method:"post", style:
阅读全文
配置Appium环境
摘要:1、安装node和npm,你可以到以下链接去下载 node 安装包 https://nodejs.org/zh-cn/download/ windows安装的时候记得勾选 Add to path (添加到环境变量) ubuntu输个命令就行 sudo apt-get update sudo apt-
阅读全文
html单选框 bootstrap模态框里面的单选框 和jq取值
摘要:html <ul class="span8"> <input type="radio" name="insu_type" class="insu_type" value="1"><span>寿险</span> <input type="radio" name="insu_type" class="i
阅读全文
解决输入框总被浏览器记住的记录遮挡住的问题
摘要:解决方案: 在input框中加入 autocomplete="off" 这个属性,禁用该输入框自动填充历史记录。
阅读全文
python 字典列表/列表套字典 去重重复的字典数据
摘要:原文引自:https://blog.csdn.net/weixin_37994148/article/details/99731818 第一种 def deleteDuplicate(li): func = lambda x, y: x if y in x else x + [y] li = red
阅读全文
ajax把数据return出去
摘要:添加async: false,即修改此方法为同步
阅读全文
js把列表转换成字符串
摘要:JSON.stringify(列表变量名) python后台接收时转换成列表 json.loads转换 python列表抓json json.dumps(列表名称) js中转换成数组 JSON.parse(python传过来的列表名称)
阅读全文
deform表单
摘要:安装deform pip install pyramid_deformpip install js.deform deform表单库介绍 与pyramid同属Pylons Project表单库 Colander:定义表单结构 Peppercom:序列化和反序列化 Chameleon:模板引擎 dev
阅读全文
Python-使用unrar库时Couldn't find path to unrar library的解决办法
摘要:原文引自:https://www.cnblogs.com/sch01ar/p/8687517.html 在Pycharm安装完unrar后,还要安装rar官方的库 不然运行的时候会抛出Couldn't find path to unrar library的错误 Windows: 下载rarlib的库
阅读全文
mako模板语言
摘要:原文链接:https://blog.csdn.net/iweaming/article/details/49816165 原文链接:https://www.cnblogs.com/ubunoon/archive/2012/07/27/2611524.html 入门 Template类是创建模板和渲染
阅读全文
SQLAlchemy用法
摘要:查询 DBSession.query('表名').all() # 查询全部 DBSession.query('表名').filter(表名.字段名==查询值).all() # 查询字段名是查询值的所有数据 DBSession.query('表名').filter_by(字段名=查询值).all()
阅读全文
sqlite用法
摘要:原文链接:https://blog.csdn.net/qq_31186123/article/details/81014601 1、安装sqlite3 ubuntu下安装sqlite3直接在终端运行命令: sudo apt-get install sqlite3 查看版本信息: sqlite3 -v
阅读全文
5.7修改密码
摘要:set password for root@localhost='mysql'; centos5.8强制修改mysql的root密码 默认mysql的配置文件vi /etc/my.cnf 有些可以在cat /home/.my.cnf 查看mysql的root密码,有些则无. 如果没有.my.cnf,
阅读全文
pyramid基本用法
摘要:模板 alchemy:基础功能加数据库--常用 starter:只包含pyramid最基本功能,简单模板,无数据库 zodb: 创建项目 pcreate -s alchemy 项目名称 项目创建完成后进入到项目路径 python setup.py develop # 不会把代码复制过去,会在site
阅读全文
only_full_group_by问题
摘要:2、修改MySQL配置文件 Linux下/etc/mysql/mysql.conf.d/mysqld.cnf或Windows下My.ini 注意在[mysqld]段下添加,直接加到最后一行无效。 添加以下代码: sql_mode= STRICT_TRANS_TABLES,NO_ZERO_IN_DAT
阅读全文
linux环境下安装pyramid和新建项目的步骤
摘要:转自https://www.jb51.net/article/43815.htm 1. 安装python虚拟环境 virtualenv --no-site-packages env 2. 安装pyramid $ env/bin/easy_install pyramid 3. 使用alchemy模板,
阅读全文
scrapy shell的使用
摘要:安装IPython pip install IPython==2.4.1 使用方法: scrapy shell http://www.itcast.cn/channel/teacher.shtml response.url:当前响应的url地址response.request.url:当前响应对应的
阅读全文
logging.basicConfig配置文件
摘要:import sys, logging logging.basicConfig(level=logging.INFO, # 日志等级 # filename: 指定日志文件名 format='levelname:%(levelname)s filename: %(filename)s ' 'outpu
阅读全文
scrapy框架--?乱码unicode
摘要:安装 pip install scrapy 建立一个爬虫项目 scrapy startproject 项目名称 scrapy startproject itcast 进入itcast文件夹 生成一个爬虫 scrapy genspider 爬虫名称 "爬虫范围" scrapy genspider it
阅读全文