Python base64编码解码实例
作者:junjie 时间:2022-06-11 07:08:27
Python中进行Base64编码和解码要用base64模块,代码示例:
#-*- coding: utf-8 -*-
import base64
str = 'cnblogs'
str64 = base64.b64encode(str)
print str64 #Y25ibG9ncw==
print base64.b64decode(str64) #cnblogs
标签:Python,base64,编码,解码
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
Case和If哪个更好用?
2009-10-28 18:25:00
Discuz7 的提示效果如何实现
2010-01-13 13:10:00
![](https://img.aspxhome.com/file/UploadPic/20101/13/2010113131444838s.jpg)
使用 WinHttpRequest 伪造 Referer (附实战代码)
2010-08-24 18:28:00
![](https://img.aspxhome.com/file/UploadPic/20108/24/20100807005911195-14s.jpg)
Access中的模糊查询
2007-11-18 14:57:00
tensorflow训练中出现nan问题的解决
2023-02-10 09:34:09
pyTorch深入学习梯度和Linear Regression实现
2023-05-12 01:00:45
![](https://img.aspxhome.com/file/2023/5/89435_0s.png)
php中支持多种编码的中文字符串截取函数!
2023-09-27 02:08:15
python冒泡排序算法的实现代码
2021-09-08 03:48:27
python 移动图片到另外一个文件夹的实例
2022-09-17 07:56:14
Python入门教程(四十)Python的NumPy数组创建
2023-11-14 08:36:32
![](https://img.aspxhome.com/file/2023/0/100820_0s.png)
用Python画一个LinkinPark的logo代码实例
2022-09-27 05:52:19
![](https://img.aspxhome.com/file/2023/9/90339_0s.png)
Python列表的深复制和浅复制示例详解
2023-01-29 01:26:47
![](https://img.aspxhome.com/file/2023/9/68459_0s.png)
Python安装Graphviz 超详细图文教程
2023-02-27 16:11:18
![](https://img.aspxhome.com/file/2023/1/75891_0s.jpg)
Python通过wordcloud库实现将单词生成词云
2022-02-24 20:17:18
![](https://img.aspxhome.com/file/2023/3/83843_0s.png)
python二分法实现实例
2023-02-16 05:09:46
ASP+AJAX做类似google的搜索提示
2008-10-24 13:49:00
Python+Opencv实现表格边框线检测
2023-08-11 04:55:14
![](https://img.aspxhome.com/file/2023/1/61971_0s.png)
python树莓派红外反射传感器
2022-12-05 16:11:47
![](https://img.aspxhome.com/file/2023/9/89399_0s.jpg)
phpstorm断点调试方法图文详解
2023-05-30 01:06:40
![](https://img.aspxhome.com/file/2023/9/55259_0s.jpg)
python运行其他程序的实现方法
2022-11-15 05:18:09