REST API on Multisite causes Server Error 500
-
Hey there,
I have a multisite running 4.7.2.
When trying to access https://site.com/wp-json I get 404.
When trying to access https://site.com/wp-json/, I get Internal Server Error 500.
When I researched, I found that the 500 was essentially being caused due to way too many redirects, as presumably, either the redirect to wp-json/ wasn’t being found or redirect wasn’t working correctly.
[Sun Feb 12 19:45:46 2017] [error] Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace. [Sun Feb 12 19:45:46 2017] [debug] core.c(3093): [client 66.187.239.11] r->uri = /wp-json/ [Sun Feb 12 19:45:46 2017] [debug] core.c(3099): [client 66.187.239.11] redirected from r->uri = /wp-json/ [Sun Feb 12 19:45:46 2017] [debug] core.c(3099): [client 66.187.239.11] redirected from r->uri = /wp-json/
And my .htaccess:
RewriteEngine On RewriteBase / <IfModule mod_deflate.c> <filesMatch "\.(js|css|html|php)$"> SetOutputFilter DEFLATE </filesMatch> </IfModule> # Rewrite www.domain.com to domain.com # RewriteCond %{HTTP_HOST} ^www\.(.*) # RewriteRule ^(.*) https://%1/$1 [R,L] RewriteCond %{HTTP_HOST} !^$ RewriteCond %{HTTP_HOST} ^www\.(.*) [NC] RewriteRule ^(.*)$ https://%1/$1 [R=301,L] #uploaded files RewriteRule ^(.*/)?files/$ index.php [L] RewriteRule ^(.*/)?files/(.*) wp-includes/ms-files.php?file=$2 [L] # add a trailing slash to /wp-admin RewriteCond %{REQUEST_URI} ^.*/wp-admin$ RewriteRule ^(.+)$ /$1/ [R=301,L] RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule . - [L] RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-.*) $2 [L] RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L] RewriteRule . index.php [L]
Any clue how to fix this?
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘REST API on Multisite causes Server Error 500’ is closed to new replies.