用php解压缩javascript内容

iknow there is online sites to unpack compressed javascript content , but i want to know how to do it with php because i want to unpack it and use preg_match to get specified data

here is exemple : eval(function(p,a,c,k,e,r){e=String;if(!''.replace(/^/,String)){while(c--)r[c]=k[c]||c;k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('(0(){4 1="5 6 7 8";0 2(3){9(3)}2(1)})();',10,10,'function|b|something|a|var|some|sample|packed|code|alert'.split('|'),0,{}))

You have to evaluate and parse the functions one by one and add the whitespace and formatting to it.

I wrote a unpacker class for that purpose, but already answered the question on another stackoverflow question here where you'll find the link to the project files on Git.