is there a config in nginx for this type of redirection?

I had to deploy a project built with laravel in a docker container using docker-compose, nginx and php-fpm.

I succeeded with all the configurations for nginx and the reverse proxy. but i only have a problem left.

This kind of URL is being recognized as an asset instead of a .php extension. Im using a tinymce plugin

This is my nginx host config:

server {

  listen 80;

  location / {
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;


And this is my docker nginx conf:

server {

  listen 80 default_server;
  listen [::]:80 default_server;

  server_name localhost;
  root /var/www/vma/public;
  index index.php index.html index.htm;

  location / {
    try_files $uri $uri/ /index.php$is_args$args;

  # Pass PHP scripts to PHP-FPM
  location ~ ^(.+.php)(.*)$ {
    try_files $uri /index.php =404;
    fastcgi_split_path_info ^(.+.php)(.*)$;
    fastcgi_pass vma_php_server:9000;
    fastcgi_index index.php;
    include fastcgi_params;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_param PATH_INFO $fastcgi_path_info;

  error_log /var/log/nginx/error.log;
  access_log /var/log/nginx/access.log;


Source: StackOverflow