Пример #1
0
 /**
  * Add icon filenames for attachments missing an icon
  * (See AttachmentsUpdate::add_icon_filenames() in update.php for details )
  */
 public function add_icon_filenames()
 {
     // Access check.
     if (!JFactory::getUser()->authorise('core.admin', 'com_attachments')) {
         return JError::raiseError(404, JText::_('JERROR_ALERTNOAUTHOR') . ' (ERR 151)');
     }
     require_once JPATH_ADMINISTRATOR . '/components/com_attachments/update.php';
     $msg = AttachmentsUpdate::add_icon_filenames();
     $this->setRedirect('index.php?option=' . $this->option, $msg);
 }
Пример #2
0
 function add_icon_filenames()
 {
     global $option;
     require_once JPATH_ADMINISTRATOR . DS . 'components' . DS . 'com_attachments' . DS . 'update.php';
     $msg = AttachmentsUpdate::add_icon_filenames();
     $this->setRedirect('index.php?option=' . $option, $msg);
 }