请选择 进入手机版 | 继续访问电脑版

简单实用单页制作教程xiuno程序(修罗教程)

[复制链接]
查看3658 | 回复1 | 2019-2-21 08:29 | 显示全部楼层 |阅读模式
简单实用单页制作教程xiuno程序(修罗教程)

采用插件机制:

新建目录和文件,假定插件名为 zidiu_plugin:

  1. plugin/
  2.     zidiu_plugin/
  3.         conf.json (配置文件)
  4.         icon.png (图标宽高:54*54)
  5.         hook/
  6.            index_route_case_end.php  (插入点,该插入点在 index.php)
  7.         hello.php (你的业务逻辑文件)
复制代码
conf.json 内容:

  1. {
  2.     "name":"我的第一个 Xiuno BBS 插件",
  3.     "brief":"我的插件介绍。",
  4.     "version":"1.0",
  5.     "bbs_version":"4.0",
  6.     "installed":0,
  7.     "enable":0,
  8.     "hooks_rank":[],
  9.     "overwrites_rank":[],
  10.     "dependencies":[]
  11. }
复制代码
index_route_case_end.php 内容:
  1. case 'hello': include APP_PATH.'plugin/zidiu_plugin/hello.php'; break;
复制代码
hello.php 内容:
  1. <?php
  2. message(0, 'Hello, Plugin');
  3. ?>
复制代码
网址访问:http://mydomain.com/?hello.htm

修罗程序简单实用的单页制作教程就到此结束了!
香蕉 | 2019-8-20 06:01 | 显示全部楼层
学习了,感谢自丢教程网
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

UID
1
贡献
387
丢币
38902
主题
4607
回帖
116
注册时间
2018-9-25
最后登录
2024-4-16