基本信息
源码名称:js 实现Unicode加密解密 示例代码下载
源码大小:0.89KB
文件格式:.html
开发语言:js
更新时间:2016-06-27
友情提示:(无需注册或充值,赞助后即可获取资源下载链接)
嘿,亲!知识可是无价之宝呢,但咱这精心整理的资料也耗费了不少心血呀。小小地破费一下,绝对物超所值哦!如有下载和支付问题,请联系我们QQ(微信同号):813200300
本次赞助数额为: 2 元×
微信扫码支付:2 元
×
请留下您的邮箱,我们将在2小时内将文件发到您的邮箱
源码介绍
<title>汉字和Unicode编码互转</title> <script Language=Javascript> var classObj= { ToUnicode:function(str) { return escape(str).replace(/%/g,"\\").toLowerCase(); }, UnUnicode:function(str) { return unescape(str.replace(/\\/g, "%")); }, copyingTxt:function(str) { document.getElementById(str).select(); document.execCommand("Copy"); } } </script> <textarea id=codes style="width:500px;height:300px"></textarea><br><br> <input type=button value=Unicode加密 id="id1" onclick=javascript:codes.value=classObj.ToUnicode(codes.value)> <input type=button value=Unicode解密 id="id2" onclick=javascript:codes.value=classObj.UnUnicode(codes.value)> <input type=button value=复制文本 onclick=javascript:classObj.copyingTxt("codes")> <input type=button value=清空内容 onclick=javascript:codes.value="">