markocupic/contao-oauth2-client 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

markocupic/contao-oauth2-client

最新稳定版本:1.2.3

Composer 安装命令:

composer require markocupic/contao-oauth2-client

包简介

Contao OAuth2 Client

README 文档

README

Logo Marko Cupic

Contao OAuth2 Client

This extension serves as a base plugin for OAuth2 Login Bundles like contao-github-login or contao-azure-login and contains a backend and frontend authenticator.

demo.mp4

Follow these steps to create your custom oauth2-login plugin.

  • Create a bundle and name it vendorname/contao-***-login
  • In your composer require 'markocupic/contao-oauth2-client', the OAuth base extension league/oauth2-github an e.g. league/oauth2-client. Have a look at knpuniversity/oauth2-client-bundle to find the client library of your choice.
  • Create for your backend and frontend login the ***BackendClientFactory class (e.g. GoogleBackendClientFactory) and ***FrontendClientFactory class (e.g. GoogleFrontendClientFactory). Both classes have to extend Markocupic\ContaoOAuth2Client\OAuth2\Client\AbstractClientFactory.
  • As client name you should choose something like this: github_frontend or google_backend. Use only letters and the underscore.
  • Create your button generator class ButtonGenerator that has to implement Markocupic\ContaoOAuth2Client\ButtonGenerator\ButtonGeneratorInterface.
  • If the Contao user is not identified by the claim email, you have to write your own token handler that has to implement Markocupic\ContaoOAuth2Client\OAuth2\Token\TokenHandlerInterface.
  • Create your Extension and Configuration class in the src/DependencyInjection folder.
  • Create your button and store it in the templates/backend directory of your bundle.
  • Create the frontend template mod_login_***.html.twig that extends @MarkocupicContaoOAuth2Client/frontend/modules/_mod_login_oauth2_base.html.twig and store it under contao\templates\modules\mod_login_***.html.twig.
  • Create the login button component and store it in under templates\component\_login_button.htl.twig.

统计信息

  • 总下载量: 514
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 0
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-3.0-or-later
  • 更新时间: 2024-01-03

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固