/** * @param Settings $settingsProvider */ public function injectSettingsProvider(Settings $settingsProvider) { $key = 'tx_' . strtolower($settingsProvider->get('extensionName')) . '_' . $settingsProvider->get('pluginName'); if (array_key_exists($key, $_FILES)) { foreach ($_FILES[$key]['name'] as $fieldName => $fileName) { $this->files[$fieldName] = array('name' => $fileName, 'type' => $_FILES[$key]['type'][$fieldName], 'tmp_name' => $_FILES[$key]['tmp_name'][$fieldName], 'error' => $_FILES[$key]['error'][$fieldName], 'size' => $_FILES[$key]['size'][$fieldName]); } } }
/** * @param Form $form */ protected function writeToCache(Form $form) { if ($this->settingsProvider->getIsCacheDisabled()) { return; } $cachePath = $this->getCachePath(''); if (!file_exists($cachePath)) { mkdir($cachePath, 0777, TRUE); file_put_contents($this->getCachePath('index.html'), ''); } $file = $this->getCachePath($form->getListId() . '.mc'); file_put_contents($file, serialize($form)); }
/** * @param Settings $provider */ public function injectSettingsProvider(Settings $provider) { $provider->initialize($this->extensionName); $this->settings = $provider->getAll(); }
public function injectSettingsProvider(Settings $settings) { $this->countryListPath = $settings->get('countryLists'); }