PHP array fix for older PHP version
Cleanup, design cleanup