admin管理员组

文章数量:1321832

Is there any way to change a site's homepage (Settings -> Reading), via API? We're running a React app with a Headless WP 'backend', and I'd like to let users change the homepage of their sites though our app.

I searched but couldn't find a solution to this.

Thanks

Is there any way to change a site's homepage (Settings -> Reading), via API? We're running a React app with a Headless WP 'backend', and I'd like to let users change the homepage of their sites though our app.

I searched but couldn't find a solution to this.

Thanks

Share Improve this question asked Sep 22, 2020 at 20:21 Ilya GurmanIlya Gurman 1
Add a comment  | 

2 Answers 2

Reset to default 0

It appears you can change some settings via the REST API, but it doesn't look like the Home Page is one of them. At least, it doesn't seem to appear in the REST API > Site Settings documentation.

Well you can't really change the whole homepage using API. Instead you could fetch different parts like Posts, Categories and display them using the API.

本文标签: pluginsAbility to change homepage on Wordpress using API