Group.js converted to php.