[wp-trac] [WordPress Trac] #46381: WordPress multisite API CORS issue with headers (v5)
WordPress Trac
noreply at wordpress.org
Fri Mar 1 00:42:21 UTC 2019
#46381: WordPress multisite API CORS issue with headers (v5)
--------------------------+------------------------------
Reporter: kacalica | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: REST API | Version:
Severity: major | Resolution:
Keywords: | Focuses: rest-api
--------------------------+------------------------------
Comment (by elrae):
Can you visit the URL http://XXX.XXX.XXX.XX/firstcivdivcareers/wp-
json/wp/v2/posts/ directly in your browser and get a response? If so,
check to make sure it's not redirecting you to another page or needs
authentication. Visit this URL when you're not logged into the admin to
rule out permission issues. To verify the response of that, open chrome
inspect tools, click on the network tab, load the wp-json page above, and
look in the Status column. It should return a 200 status, anything else
and you have issues.
Alternatively, you can try adding the following directive to your
.htaccess file:
Header set Access-Control-Allow-Origin "*"
--
Ticket URL: <https://core.trac.wordpress.org/ticket/46381#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list