add changes for the new php module
to use resource instead of cfg file