2013-02-23 285 views
1

我试图从查看页面发送大量数据到控制器,我需要使用一种压缩技术 所以我选择JSZip压缩数据,我能够压缩数据,但我'我无法解压缩数据使用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. 

回答