简体   繁体   English

如何从php外部站点登录drupal

[英]how to login in drupal from php external site

I'm new in drupal I want to login to my drupal site from a php site, I'm using the service and oauth module. 我是drupal的新手,我想从php站点登录我的drupal站点,我正在使用service和oauth模块。 Already tried login with session authentication and returns the ssesion id and name what I don't know is how to redirect to the drupal site logged. 已经尝试使用会话身份验证登录并返回会话ID和名称,但我不知道该如何重定向到已记录的Drupal站点。 I also try the 3 legged authentication using my own consummer but if the user is not logged in drupal it ask to login and then do the token authentication so I'm stuck in how to login the user before the 3 legged authentication. 我也尝试使用自己的用户使用3足身份验证,但是如果用户未登录drupal,它会要求先登录然后进行令牌身份验证,因此我将陷入3足身份验证之前如何登录用户的困境。 Thank for your help in advance. 感谢您的帮助。

Install services module in Drupal. 在Drupal中安装服务模块。 Configure the same to expose the login service. 配置相同以公开登录服务。 Once enabled you can call it in your php application. 启用后,您可以在php应用程序中调用它。 Refer this link for example. 例如,请参考此链接

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM