adds support for running under nginx with php-fpm

adds template nginx config file, checks for existence of "apache_get_modules" function to check if running under apache or nginx.