Answer the question
In order to leave comments, you need to log in
How to authorize user in react app using cookie and wp rest api?
I made an application on react and placed it on the hosting in a subfolder next to the WordPress site. Now I want to make authorization in this application for WordPress users. It seems that the easiest or most convenient way is authorization using the REST API and authorization cookies.
Here is the official documentation, but I can't figure out where to put the php code. I couldn't find any examples on the internet.
https://developer.wordpress.org/rest-api/using-the...
Tell me
where to write something.
Answer the question
In order to leave comments, you need to log in
This particular example with cookies does not suit you - you need to do a lot of improvements and you still have to deal with WP. But this does not mean that it will not work without pain.
The plugins for external authorization, described at the very bottom of this ill-fated manual, may be suitable for you. Choose the authorization to your taste and go ahead.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question