myaac/plugins/example.json
slawkens e52a301d9e [WIP] nikic/fast-route implementation
I will describe it more in Pull Request
2021-06-08 19:17:38 +02:00

51 lines
1.4 KiB
JSON

{
"enabled": 0,
"name": "Example Plugin",
"description": "This is just an example of a Plugin for MyAAC.",
"version": "1.0",
"author": "nobody",
"contact": "nobody@example.org",
"require": {
"myaac": "0.4.3",
"myaac_": ">=0.7,<1.0", // support for defining versions like in composer (since 0.8)
"php": "5.2.0",
"php_": ">5.4,<7.0", // support for defining versions like in composer (since 0.8)
"database": "21",
"php-ext": "curl", // php extension needs to be installed (since 0.8)
"ext-curl": ">5.0", // php extension with version specifiec (since 0.8)
"table": "accounts", // table need to exist in database (since 0.8)
"column": "players.online" // column need to exist in database (since 0.8)
},
"install": "plugins/example/install.php",
"uninstall": [
"plugins/example.json",
"plugins/example-directory",
"templates/other-directory"
/***
this is example of multi line comment
1. list example
2. something
****/
],
"hooks": {
"Example Hook": {
"type": "BEFORE_PAGE",
"file": "plugins/example/before.php"
}
},
"routes": {
"First Route": {
"pattern": "/YourAwesomePage",
"file": "plugins/your-plugin/your-awesome-page.php",
"method": "GET",
"priority": "130"
},
"Second Route": {
"pattern": "/YourSecondRoute",
"file": "plugins/your-plugin/your-awesome-page-two.php",
"method": "GET,POST",
"priority": "120"
}
}
}