You need to write a rule in htaccess, which replaces a specific .js file with .php. I tried to prescribe something like that
RewriteRule ^/js/index.php/x.js ^.*\.php But it does not work. There is a ready solution, but for nginx
location = /js/index.php/x.js { rewrite ^(.*.php)/ $1 last; }
AddHandler x-httpd-php .js- AK ♦