1 // jquery 加密 2 <script src="__PUBLIC__/JQuery/jquery-1.8.3.min.js"></script> 3 <script src="__PUBLIC__/JQuery/jquery.base64.js"></script> // 此加密js必须 4 <script> 5 6 <?php $abc = $cate;?> 7 8 var cate = "<?php echo $abc;?>"; 9 $(".print").bind().click(function () { 10 11 var str=''; 12 $(":checkbox").each(function(){ 13 if($(this).prop("checked")){ 14 str+='_'+$(this).val(); 15 } 16 }); 17 var ids = str.substr(1); 18 ids = $.base64.encode(ids); 19 console.log(ids); 20 window.location.href = "<?php echo U('payindex','',false);?>/ids/"+ids+/cate/+cate; 21 }); 22 23 24 // php解密 25 $kcids = $_GET['ids']; 26 $kcids = base64_decode($kcids);
来源:https://www.cnblogs.com/G921123/p/10167574.html