Download the PHP package widuu/think-addons without Composer

On this page you can find all versions of the php package widuu/think-addons. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package think-addons

think-addons

tp6 (Thinkphp) 插件扩展包,更友好兼容 Thinkphp 原生框架。

插件路由分发器 think\addons\dispatch\Controller 继承 think\route\Dispatch

插件支持 event/middleware/provider 配置,没有将事件封装成 hook 函数,使用原生 \think\facade\Event 操作,让开发者能够快速上手,如果你习惯使用 hook 函数,只需要将下边的方法添加到 app\common.php 中即可

更细化的配置,能够根据配置来进行按需加载

安装

全局配置

config\addons.php 文件

当运行到某个插件时譬如 test 插件,会自动加载插件下的 (公共函数) common.php (服务注册) provider.php (事件) event.phpTest.php 中的事件。

但是 provider.php/event.php/Test.php 文件中的事件和服务并不全局调用,假如你想在任何地方调用,可以开启上方的自动加载或者将这些配置到对应的配置数组中

注:生产环境中(非 Debug)模式,会在缓存读取,所以有新的插件记住清除缓存,缓存名称在配置中自定义的。

生成插件

使用如下命令行可以自动生成插件

目录如下

我们插件实现类中可以通过注释修改事件名称,以 Test.php 插件为类

插件公共方法

addons_url 中的 $url 在插件内可以 controller/action 或者 action,如果全局使用,addon/controller/action

其它使用方法请参考 thinkphp 手册即可


All versions of think-addons with dependencies

PHP Build Version
Package Version
Requires php Version >=7.1.0
topthink/framework Version ^6.0.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package widuu/think-addons contains the following files

Loading the files please wait ....