码迷,mamicode.com
首页 >  
搜索关键字:decode    ( 2985个结果
Python 爬虫 返回json内容
如果返回的是json内容 可以用requests模块自带的 response.json() 直接转成Python 字典 或者引入json模块 用json.loads(response.content) 将返回内容 保存到文件里 返回的内容转码 response.decode('utf-8') ...
分类:编程语言   时间:2018-11-22 02:30:56    阅读次数:231
11.20 小程序开发总结 (1)
小程序接口: 1.getCurrentPages 获取页面前几个页面的所有app.js 信息 (太强了!!我竟然才知道) 用途:获取上个页面的函数来获取做数据交互, 类似react 父级给子级传参,函数等. 代码: 此时获取到上个页面所有的函数,及其参数; 2.小程序二维码传参,分享传参 需求:新版 ...
分类:微信   时间:2018-11-20 18:20:32    阅读次数:335
oracle decode函数
decode的几种用法1:使用decode判断字符串是否一样DECODE(value,if1,then1,if2,then2,if3,then3,...,else)含义为IF 条件=值1 THEN RETURN(value 1)ELSIF 条件=值2 THEN RETURN(value 2) ... ...
分类:数据库   时间:2018-11-20 15:08:49    阅读次数:140
535. Encode and Decode TinyURL(rand and srand)
TinyURL is a URL shortening service where you enter a URL such as https://leetcode.com/problems/design-tinyurl and it returns a short URL such as http ...
分类:Web程序   时间:2018-11-19 13:33:08    阅读次数:213
json文件操作中遇到的小问题(容易忽视的地方)
UnicodeDecodeError: ‘gbk‘ codec can‘t decode byte 0xa8 in position 18: illegal multibyte sequence json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
分类:Web程序   时间:2018-11-19 12:31:54    阅读次数:376
Python设置默认编码为utf8
对于python.x来说,安装时系统默认的编码方式为ascii。因此,若编码中出现非ascii编码(如汉字),运行时就会报错:UnicodeDecodeError: 'ascii' codec can't decode byte 0x?? in position 1: ordinal not in ...
分类:编程语言   时间:2018-11-19 11:04:12    阅读次数:130
python学习(24) 使用Xpath解析并抓取美女图片
Xpath最初用来处理XML解析,同样适用于HTML文档处理。相比正则表达式更方便一些 Xpath基本规则 下面举例使用下 result.decode(‘utf-8’) 可以补全缺失的html格式字符串html.xpath(‘//*’)查找根节点下所有子孙节点html.xpath(‘//a[@cla ...
分类:编程语言   时间:2018-11-18 22:38:26    阅读次数:325
python读取excel文件
#coding=utf-8 import xlrd #路径前加 r,读取的文件路径 file_path = r'D:/1.xlsx' #文件路径的中文转码 file_path = file_path.decode('utf-8') #获取数据 data = xlrd.open_workbook(fi... ...
分类:编程语言   时间:2018-11-18 11:30:10    阅读次数:189
Selenium定位不到指定元素原因之iframe(unable to locate element)
浏览过程中,图片中的内容可能太小,无法看清,可以>右键>在新标签中打开 Outline 项目原因,需要用selenium实现模拟登陆、模拟上传文件,自然就需要模拟点击【上传】按钮; 模拟点击之前需要通过selenium提供的“方法”去定位到要点击的元素; 模拟登陆过程中,全程都可以定位到需要点击的元 ...
分类:其他好文   时间:2018-11-17 17:57:02    阅读次数:305
thinkphp5.0 CURL用post请求接口数据
个人记录一下哈 ...
分类:Web程序   时间:2018-11-15 16:13:09    阅读次数:1464
2985条   上一页 1 ... 76 77 78 79 80 ... 299 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!