hypejunction / hypeshortcode
该软件包已被废弃且不再维护。未建议替代软件包。
短代码支持
1.2.0
2018-06-29 20:01 UTC
Requires
- php: >=7.0
- composer/installers: ~1.0
This package is not auto-updated.
Last update: 2020-01-18 13:22:33 UTC
README
添加自定义 BB-style 短代码支持
使用方法
注册短代码
elgg()->shortcodes->register('mycode'); // then add a view in shortcodes/mycode // view vars will contain attributes of the shortcode
生成短代码标签
elgg()->shortcodes->generate('mycode', [ 'foo' => 'bar', ]);
展开短代码
elgg()->shortcodes->expand($text);
去除短代码
elgg()->shortcodes->strip($text);