Joomla plugin install xml -- install file to different folder(Joomla 插件安装 xml -- 将文件安装到不同的文件夹)
问题描述
是否可以将 Joomla 插件中的文件安装到非插件目录?
Is it possible to install a file from a Joomla plugin to a non-plugin directory?
例如——默认情况下,Joomla 插件安装 xml 如下所示:
For example-- by default a Joomla plugin install xml looks like this:
<?xml version="1.0" encoding="utf-8"?>
<install version="1.5" type="plugin" group="mycomponent" method="upgrade">
<name>MyPlugin</name>
<author>Me Myself</author>
<creationDate>January 29, 2011</creationDate>
<copyright>Copyright (C) 2011 ME</copyright>
<license>http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL</license>
<authorEmail>me@mysite.com</authorEmail>
<authorUrl>www.mysite.com</authorUrl>
<version>1.5</version>
<description>My cool plugin.</description>
<files>
<filename plugin="myplugin">myplugin.php</filename>
</files>
<params />
</install>
这会将 myplugin.php 文件安装到/plugins/mycomponent plugins 文件夹中.
This will install the myplugin.php file to the /plugins/mycomponent plugins folder.
但是,如果我想安装一些图像文件以使我的插件看起来更好,并且想将它们放在/images 文件夹中,有没有办法提供该路径?
However, if I want to install some image files to make my plugin look nicer, and want to drop those in the /images folder, is there a way to supply that path?
谢谢
推荐答案
<!-- Site Main Media File Copy Section -->
<media destination="com_helloworld">
<filename>image.png</filename>
<filename>flash.swf</filename>
</media>
http://docs.joomla.org/Components:xml_installfile
这篇关于Joomla 插件安装 xml -- 将文件安装到不同的文件夹的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:Joomla 插件安装 xml -- 将文件安装到不同的文件夹
- 如何定位 php.ini 文件 (xampp) 2022-01-01
- Mod使用GET变量将子域重写为PHP 2021-01-01
- 没有作曲家的 PSR4 自动加载 2022-01-01
- PHP Count 布尔数组中真值的数量 2021-01-01
- Laravel 仓库 2022-01-01
- 正确分离 PHP 中的逻辑/样式 2021-01-01
- 从 PHP 中的输入表单获取日期 2022-01-01
- SoapClient 设置自定义 HTTP Header 2021-01-01
- Oracle 即时客户端 DYLD_LIBRARY_PATH 错误 2022-01-01
- 带有通配符的 Laravel 验证器 2021-01-01
