Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Auth user from Laravel to Wordpress Database

I have a existing site in wordpress. User register only by web (wordpress). How to authenticate user from Laravel to the wordpress DB.

like image 259
dev21 Avatar asked Feb 28 '18 08:02

dev21


Video Answer


1 Answers

There are a lot of ways to do this. You could:

  • Use a custom authentication driver on your Laravel app to use WordPress database. Hampel's package does this.
  • Use a custom authentication provider to authenticate WordPress users. Laravel WP User package can do this, and it also support REST API.
  • Override Laravel's hashing to make WordPress compatible password hashes using Laravel WP Password package. You can read more about this here.
  • Replace WordPress's built-in authentication.
  • Use Auth0.

There are probably still more ways to do this.

like image 144
sykez Avatar answered Oct 24 '22 20:10

sykez