location / {
if (!-e $request_filename) {
rewrite ^([^\.]*).html(.*)$ $1.php$2 last;
}
}