How would I go about doing this:
I want all urls that are:
domain.org/directory/file-name.html
to be redirected to that same file name but with an expanded directory path
domain.org/directory/subdirectory/file-name.html
I am imagining/learning that this is possible, but must be done via a 301 permanent redirection. I just can’t seem to cut through the formatting for .htaccess files to accomplish this. My CMS is taking all my relative links and turning them into root relative… so taking: "../directory/file-name.html" and turning it into "/directory/file-name.html"
So a link that leads to:
domain.org/directory/subdirectory/assets/style.css
via relative links for example, is being turned into:
domain.org/directory/assets/style.css
And breaking.
Any help would be greatly appreciated.
[reposting in General and PHP]
Thanks,