从Laravel向WordPress数据库授权用户 [英] Auth user from Laravel to Wordpress Database

查看:57
本文介绍了从Laravel向WordPress数据库授权用户的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在wordpress中有一个现有站点.用户仅通过网络(wordpress)进行注册.如何验证从Laravel到wordpress数据库的用户.

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

推荐答案

有很多方法可以做到这一点.您可以:

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.

可能还有更多方法.

这篇关于从Laravel向WordPress数据库授权用户的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆