Woocommerce REST API 404 error

后端 未结 3 1176
旧巷少年郎
旧巷少年郎 2021-01-02 16:34

Since woocommerce released the 2.1 version with REST API feature, I tried to use it: I activated the API on my woocommerce admin panel but when I try to call the curl: http:

3条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-02 17:04

    Apart from answer shared above: Settings -> Permalinks. On Default Settings radio group, select the "Post name" one. Save the changes.

    I also had to manually update .htaccess file to reflect the changes I made (permalinks to "Post name", and the little Wordpress help text shown on the bottom of the page was really helpful:

    If your .htaccess file was writable, we could do this automatically, but it isn’t so these are the mod_rewrite rules you should have in your .htaccess file. Click in the field and press CTRL + a to select all.

    Basically copy the new mod_rewrite rules as instructed by Wordpress above and manually update your .htaccess file! doing this worked for me!

提交回复
热议问题