location ~ [^/]\.php(/|$) {
    fastcgi_pass  unix:/tmp/php-cgi7.4.sock;
    fastcgi_index index.php;
    include fastcgi.conf;
    include pathinfo.conf;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;

    # Keep ThinkPHP ?s=/... style routing working on PHP 7.4 projects.
    if ($query_string ~ "^s=(.*)$") {
        set $path_info "/$1";
    }
}
