I think this really is some trouble with the Apache configuration because previously focus on the prior host company with similar PHP/MySQL configuration. During my application, customers can remove photos by visiting URIs such as this:


The paramater id is definitely an id of the photo to become removed, the parameter ret is really a relative URL where user ought to be rerouted after removing the photo but after hitting a hyperlink like this I recieve 404 Not Found error using the text:

Not Found

The requested URL /public/my-account/remove-media/id/9/ret/my-account/edit-album/id/1 was not found on this server.

Though previously focus on these host company and so i guess it is only some easy Apache configuration problem?

Yet another factor, there's a htaccess file that changes the document root to /public:

RewriteEngine On

RewriteRule ^\.htaccess$ - [F]

RewriteCond %{REQUEST_URI} =""
RewriteRule ^.*$ /public/index.php [NC,L]

RewriteCond %{REQUEST_URI} !^/public/.*$
RewriteRule ^(.*)$ /public/$1

RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^.*$ - [NC,L]

RewriteRule ^public/.*$ /public/index.php [NC,L]

Within the public folder there's another htaccess apply for MVC:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ /index.php [NC,L]

It's most likely because of AllowEncodedSlashes directive being set to Off. Unhealthy news is, it's set up on server level, so .htaccess will not do. If you cannot get it transformed, i quickly think modifying the applying code to deal with non-encoded strings could be what you want.

.../ret/my-account%252Fedit-album%252Fid%252F1 -> .../ret/my-account/edit-album/id/1

When the /ret/ part is definitely the final one, it should not be that a problem (all after ret is the destination).