我试图发送大量的数据从视图页面到控制器,我需要使用一种压缩技术,所以我选择JSZip压缩数据,我能够压缩数据,但我无法在视图页面中使用JSZip解压缩数据(这里压缩的内容将从控制器返回)我已经通过JSZip,但我没有找到解压的方法。
我的压缩代码:
var zip = new JSZip();
zip.file("temp.txt", JSON.stringify(buffers[0]));
var content = zip.generate({ compression: "DEFLATE" });
// here I'am sending the 'content' to the controller
// and I' am receiving compressed content from controller like 'content' and trying to decompress it.发布于 2013-03-01 15:04:43
您可以使用load()方法:http://stuk.github.com/jszip/#doc_load_data_options
https://stackoverflow.com/questions/15037353
复制相似问题