Sorts directives hash before writing php.ini template.