Including static files with no extension
-
How do I include static files that have no file extension?
_redirects and _headers files are used by Netlify, Cloudflare Pages, etc to server side rules.
~/_redirectsto set server side redirect rules
~/_headersto set server side header rulesThe debug log shows that the content type is being detected correctly, but since these files don’t have file extensions they are being treated like html pages https://plugins.trac.wordpress.org/browser/simply-static/tags/2.2.7/src/class-ss-url-fetcher.php#L181
and that is producing filenames not recognized by those platforms:
~/_redirects/index.html
~/_headers/index.htmlHow can I include these and other files while keeping the filenames the same? Is there a filter I can use, or something else?
The topic ‘Including static files with no extension’ is closed to new replies.