I want to upload and move file from my desktop to joomla component directory. eg: xml file need to hit services of specific API in a joomla component, so admin can upload this xml from component configuration and it should be moved into services directory inside that component, when admin saved configuration of the component. Is it possible in config.xml?
我想上传文件并将文件从我的桌面移动到joomla组件目录。例如:xml文件需要在joomla组件中点击特定API的服务,因此管理员可以从组件配置上传这个xml,当管理员保存组件的配置时,它应该被移动到该组件内的services目录中。是否可以在config.xml中?
1 个解决方案
#1
3
May be you can use any ajax call, like creating your own upload button by custom field there, or an ajax on save. Then afterwards use simple JFile::copy or JFile::move.
也许你可以使用任何ajax调用,比如在那里通过自定义字段创建自己的上传按钮,或者在保存时创建ajax。然后使用简单的JFile :: copy或JFile :: move。
#1
3
May be you can use any ajax call, like creating your own upload button by custom field there, or an ajax on save. Then afterwards use simple JFile::copy or JFile::move.
也许你可以使用任何ajax调用,比如在那里通过自定义字段创建自己的上传按钮,或者在保存时创建ajax。然后使用简单的JFile :: copy或JFile :: move。