I think I could use such a tool if it works really reliably. If the project contains hundreds of php files, or even more then there is no chance to check and test the result. That's the reason why it has to be reliable.
If I don't remember whether I had used variable variables in the code then the obfuscator might make to code wrong and my site won't work. This is unfortunately a deal breaker for me. It would be nice if the obfuscator could indicate that the name of a varible changed when this variable is used as a function name, variable name, class name, etc.
Vallo Reima - 2016-03-03 07:25:30 - In reply to message 1 from Csongor Halmai
Some suggestions at first:
- It's important to follow the identifiers naming rules described in the readme.
- Use the dbg=true option (don't minify) to fix the renaming issues in large projects.
- The variable variables should be used only if clearly needed.
The variable variables names (or their prefix, even better) must be specified in the identifier exclusion list ('__' prefixed identifiers are not obfuscated by default). So, in your example:
1) either specify name/prefix, like:
$obj = new PackApp(3, ['exi' => ['sum']]); // instantiate
2) or use '__'
$f = "__sum";
echo $f(3.4, 5.6);