Hi everyone i have a Php function which use JSMin to Minify JavaScript but i want a regex to replace long arguments name with a or b
function foo(long_arg_name, long_arg_name2){
alert(long_arg_name + long_arg_name);
}
to
function foo(a,b){
alert(a+b);
}
You can use this plugin:
https://github.com/promatik/PHP-JS-CSS-Minifier
It uses this minifier http://javascript-minifier.com/
Or use this script from http://javascript-minifier.com/examples
Don't forget to cache everything :)