Ok, I figured this out:
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
The single dot in the 3rd line matches any single character, but the replacement applies to the whole string. So, whatever URL you asked for, if it doesn’t match an existing file or directory name, is turned into a request for index.php. The PHP code then processes the entire original URL and decides what page to generate. All the required information is in the database, not the .htaccess. So, it does actually ‘enable’ permalinks, in the sense that it allows the PHP code to see and act on the original URL.
Related Posts:
- Rewrite /?rest_route=/ link to /wp-json/ without changing default permalink structure in apache
- index.php not loading in main folder of wordpress
- Redirect from different port to subdomain – htaccess
- WordPress 404 on Subdomain
- Only expose routes with prefix /wp-json on WordPress using Apache
- What’s the opposite of required valid user in .htaccess authentication
- How can i redirect one url to another url using .htaccess or add_rewrite_rule
- Override htacces rule only for specific directory
- Restrict uploaded files into a custom folder to logged in users by htaccess: looking for Nginx – not only Apache – solution
- How do I test to ensure that my wp-config file is protected?
- .htaccess Security Header Rules
- mod_rewrite loop, redirecting http to https on certain section of wordpress blog
- .htaccess in subdir gets ignored by WordPress’ own .htaccess in /
- Directing subdomain to main domain and keeping the subdomain format with .htaccess
- WordPress – Promoting A Dev Build In A Subdirectory To Production / Root Directory
- Redirect old domain with query paramaters
- Does WP suppresses .htaccess if permalinks are disabled?
- fix 302 redirection error on https
- Access sub-domain when root public_html is protected with .htaccess password
- Accepting special characters in querystring
- WordPress permalinks confusion
- Configure .htaccess to have a WordPress single site installation with all subdomains pointing to the same pages?
- Unable leverage Browser Caching on AWS Bitnami stack (Apache) through W3TC and Cloudfront CDN
- How to move wordpress website from hosting account to localhost
- How to block wordpress admin by htaccess
- I can access subdirectory, but not files within it
- WordPress redirection
- How To Add CSP frame ancestors in WordPress Website? [closed]
- Subfolder install not working
- Browser Caching .htaccess
- Hardening WordPress – how to set .htaccess permissions?
- Avoid duplicate content on pretty URLs with htaccess
- malware affecting backend of wordpress website-could be .htaccess file
- How can I use an .htaccess file in Nginx?
- How to automatically redirect HTTP to HTTPS on Apache servers?
- htaccess – Redirect to subfolder without changing browser URL
- Cant login to wp-admin (redirecting to homepage), But CAN login to wp-login.php
- Cant login to wp-admin (redirecting to homepage), But CAN login to wp-login.php
- Best collection of code for your .htaccess file [closed]
- Use subdomain for certain urls
- WordPress + Magento .htaccess ReWriteRule Issue (www vs. non-www)
- Admin-Ajax.php, SSL, Non-SSL
- WordPress site displaying 404 for any page apart from index
- How to avoid wordpress permalink rules to inherit in a sub-folder
- Cant block wordpress readme files
- WordPress keeps deleting .htaccess file
- .htaccess 301 vs. 302 Enforcing HTTPS
- Prevent users from browsing through the media galleries
- How to modify the .htaccess to force ssl on login and admin pages
- WordPress URL/Folder ReWrite using Htaccess
- .htaccess redirects no longer work
- Exclude subfolder from WP-redirect works with html but not php files
- Server crashed trying to restore wordpress multisite, images are not found pls help
- Create subdomain masking for each user in WordPress
- WordPress Redirect 301 register page
- .htaccess password protect all but one page
- Hardening wordpress: blocking /includes with htaccess
- Install a Network under a mapped domain
- htaccess – RewriteRule without redirect not working
- How to fix category url 404’s after category permalink change
- WordPress: Adding Security
- How can I fetch the content of a post of my wordpress domain from an other domain?
- Modify the .htaccess file
- WordPress site not working after move
- blocking access to all post/tag URIs via htaccess
- sitemap contains weird links and does not contain my pages [closed]
- want to rewrite an URL in wordpress
- how to redirect 301 my old search query string to wordpress search query string?
- How to block access to files without modifying .htaccess or ngnix config? [closed]
- how to combine wordpress htaccess on my root domain + php on subfolder
- Allow REST API over HTTP, the rest of the site forced to HTTPS
- where to add redirection rewriterule in .htaccess file?
- Trouble adding directory rewrite to htaccess under wordpress [closed]
- Conflict with Force SSL and Rewrite Rules
- htaccess getting overwritten over and over = 404 error
- I have a page using a pretty url and a mod_rewrite rule matching it. I expected it to give an error but it’s working. Why?
- How do I setup htaccess for 301 redirects, post Joomla to WordPress migration? [closed]
- Hide a subdirectory on my website hosting
- Can’t access WP site over WiFi network
- How do I do a redirect to WordPress permalink with post id via htaccess?
- Creating a copy of a website in a subdirectory, wp-admin redirect problem
- I am new in word pres my font awesome is not allow
- htaccess redirect throws an error: PHP Catchable fatal error: Object of class WP_Error could not be converted to string
- Basic Auth .htaccess on wp-login, but allow logout from woocommerce
- Why my WordPress Site Asking for HTTP Authentication?
- htaccess redirects invalid request to home page not 404
- WordPress How to rewrite URL for custom pages
- How to properly give WordPress its own directory
- WordPress permalinks is wrong. It wants me to change my htaccess file. But then site crashes
- Question with .htaccess and wp-login.php prevention
- WordPress RSS feed to external XML
- Does htaccess password keep search engines out?
- What to do after a wrong RewriteRule?
- htaccess old php pages to new wordpress ones
- different CNAME to corresponding subfolders
- block seacrh engines for all pages EXCEPT homepage
- Allowing access to certain WordPress created pages or posts with htaccess / htpasswd
- htaccess – Server Subdirectory With Different Name Than URL Subdirectory
- .htaccess seems to be required but I can not find it
- cant access website thru www only works on direct xyz.com