/webtrees/app/Http/RequestHandlers/ |
H A D | UploadMediaAction.php | 84 $filename = Validator::parsedBody($request)->string('filename' . $key); 87 if ($filename === '') { 88 $filename = $uploaded_file->getClientFilename(); 97 $filename = str_replace('\\', '/', $filename); 98 $filename = trim($filename, '/'); 100 if (preg_match('/([:])/', $filename, $match)) { 106 … if (preg_match('/(\.(php|pl|cgi|bash|sh|bat|exe|com|htm|html|shtml))$/i', $filename, $match)) { 112 $path = $folder . $filename; 128 …ges::addMessage(I18N::translate('The file %s has been uploaded.', Html::filename($path)), 'success…
|
H A D | ExportGedcomServer.php | 71 $filename = Validator::parsedBody($request)->string('filename'); 74 if (strtolower(pathinfo($filename, PATHINFO_EXTENSION)) !== 'ged') { 75 $filename .= '.ged'; 80 $data_filesystem->writeStream($filename, $resource); 84 …(I18N::translate('The family tree has been exported to %s.', Html::filename($filename)), 'success'… 87 …I18N::translate('The file %s could not be created.', Html::filename($filename)) . '<hr><samp dir="…
|
H A D | EditMediaFileAction.php | 112 $file = $media_file->filename(); 116 $old = $media_file->filename(); 127 …e media file %1$s has been renamed to %2$s.', Html::filename($media_file->filename()), Html::filen… 130 …dia file %1$s could not be renamed to %2$s.', Html::filename($media_file->filename()), Html::filen…
|
H A D | ExportGedcomPage.php | 57 $filename = $tree->name(); 60 if (strtolower(pathinfo($filename, PATHINFO_EXTENSION)) === 'ged') { 61 $download_filename = substr($filename, 0, -4); 63 $download_filename = $filename; 73 'filename' => $filename,
|
H A D | MapDataExportGeoJson.php | 75 $filename = preg_replace('/[^\p{L}]+/u', '-', $hierarchy[0] ?? 'Global') . '.geojson'; 129 $filename = addcslashes($filename, '"'); 133 ->withHeader('content-disposition', 'attachment; filename="' . $filename . '"');
|
H A D | MapDataExportCSV.php | 83 $filename = preg_replace('/[^\p{L}]+/u', '-', $hierarchy[0] ?? 'Global') . '.csv'; 171 $filename = addcslashes($filename, '"'); 175 ->withHeader('content-disposition', 'attachment; filename="' . $filename . '"');
|
H A D | UpgradeWizardStep.php | 211 $filename = $tree->name() . date('-Y-m-d') . '.ged'; 213 $data_filesystem->writeStream($filename, $stream); 217 'alert' => I18N::translate('The family tree has been exported to %s.', e($filename)),
|
H A D | ExportGedcomClient.php | 59 $filename = Validator::parsedBody($request)->string('filename'); 65 …ort_service->downloadResponse($tree, true, $encoding, $privacy, $line_endings, $filename, $format);
|
H A D | MediaFileDownload.php | 60 return redirect($media_file->filename());
|
/webtrees/app/Factories/ |
H A D | ImageFactory.php | 91 … $filename = $download ? addcslashes(string: basename(path: $path), characters: '"') : ''; 93 …mageResponse(data: $filesystem->read(location: $path), mime_type: $mime_type, filename: $filename); 117 return $this->imageResponse(data: $data, mime_type: $mime_type, filename: ''); 139 $path = $media_file->filename(); 150 $filename = $download ? basename(path: $path) : ''; 154 return $this->imageResponse(data: $data, mime_type: $mime_type, filename: $filename); 181 $path = $media_file->filename(); 214 return $this->imageResponse(data: $data, mime_type: $mime_type, filename: ''); 283 …protected function imageResponse(string $data, string $mime_type, string $filename): ResponseInter… argument 295 if ($filename === '') { [all …]
|
/webtrees/app/Services/ |
H A D | GedcomExportService.php | 98 …* @param string $filename Name of download file, with… 108 string $filename, argument 121 …ithHeader('content-disposition', 'attachment; filename="' . addcslashes($filename, '"') . '.ged"'); 145 $zip_filesystem->writeStream($filename . '.ged', $resource); 156 …->withHeader('content-disposition', 'attachment; filename="' . addcslashes($filename, '"') . $exte… 281 $filename = $tree->name(); 283 if (strtolower(pathinfo($filename, PATHINFO_EXTENSION)) !== 'ged') { 284 $filename .= '.ged'; 305 $gedcom .= "\n1 FILE " . $filename;
|
H A D | ModuleService.php | 688 ->filter(static function (string $filename): bool { 691 $module_name = basename(dirname($filename)); 701 ->map(static function (string $filename): ModuleCustomInterface|null { 702 $module = self::load($filename); 705 $module->setName('_' . basename(dirname($filename)) . '_'); 719 private static function load(string $filename): ModuleInterface|null argument 722 return include $filename; variable in Fisharebest\\Webtrees\\Services\\ModuleService 724 $module_name = basename(dirname($filename));
|
H A D | TreeService.php | 233 * @param string $filename The preferred filename, for export/download. 238 …public function importGedcomFile(Tree $tree, StreamInterface $stream, string $filename, string $en… argument 247 $tree->setPreference('gedcom_filename', $filename);
|
/webtrees/app/ |
H A D | Html.php | 81 * @param string $filename 85 public static function filename(string $filename): string function in Fisharebest\\Webtrees\\Html 87 return '<samp class="filename" dir="ltr">' . e($filename) . '</samp>';
|
H A D | MediaFile.php | 310 $bytes = $this->media()->tree()->mediaFilesystem()->fileSize($this->filename()); 320 $data = $this->media()->tree()->mediaFilesystem()->read($this->filename()); 379 public function filename(): string function in Fisharebest\\Webtrees\\MediaFile
|
/webtrees/resources/views/modals/ |
H A D | media-file-fields.phtml | 65 …of MediaFile ? $media_file->filename() : '') === '.' ? '' : dirname($media_file instanceof MediaFi… 71 …Same as uploaded file') ?>" value="<?= e(basename($media_file ? $media_file->filename() : '')) ?>"> 102 …to.jpeg" value="<?= e($media_file && $media_file->isExternal() ? $media_file->filename() : '') ?>">
|
/webtrees/app/Exceptions/ |
H A D | FileUploadException.php | 94 $filename = $uploaded_file->getClientFilename() ?? ''; 96 if ($filename !== '') { 97 $message = I18N::translate('%1$s: %2$s', e($filename), $message);
|
/webtrees/tests/ |
H A D | TestCase.php | 202 … protected function createUploadedFile(string $filename, string $mime_type): UploadedFileInterface argument 207 $stream = $stream_factory->createStreamFromFile($filename); 208 $size = filesize($filename); 210 $client_name = basename($filename);
|
/webtrees/resources/views/ |
H A D | media-page-details.phtml | 52 … Registry::elementFactory()->make('OBJE:FILE')->labelValue($media_file->filename(), $record->tree(… 56 … <?= I18N::translate('The file “%s” does not exist.', e($media_file->filename())) ?> 59 … Registry::elementFactory()->make('OBJE:FILE')->labelValue($media_file->filename(), $record->tree(…
|
/webtrees/resources/views/modules/media-list/ |
H A D | page.phtml | 133 … Registry::elementFactory()->make('OBJE:FILE')->labelValue($media_file->filename(), $media_object-… 136 … Registry::elementFactory()->make('OBJE:FILE')->labelValue($media_file->filename(), $media_object-… 146 …a filename */ I18N::translate('The file “%s” does not exist.', e($media_file->filename())), '</p>';
|
/webtrees/app/Cli/Commands/ |
H A D | CompilePoFiles.php | 64 $translation = new Translation(filename: $po_file); 68 $bytes = file_put_contents(filename: $php_file, data: $php_code);
|
/webtrees/resources/views/edit/ |
H A D | reorder-media-files.phtml | 25 <?= view('edit/reorder-card-header', ['title' => e($media_file->filename())]) ?>
|
/webtrees/app/Http/Middleware/ |
H A D | ErrorHandler.php | 49 …throw new ErrorException(message: $errstr, code: 0, severity: $errno, filename: $errfile, line: $e…
|
/webtrees/resources/views/admin/ |
H A D | trees-export.phtml | 36 … <input type="text" class="form-control" id="filename" name="filename" value="<?= e($filename) ?>">
|
/webtrees/app/Cli/ |
H A D | Console.php | 58 $config = parse_ini_file(filename: Webtrees::CONFIG_FILE);
|