protected function FileSearch::getExifTagmarker in Search File Attachments 8
Defines the IPTC fields to be used for the search index.
Return value
array A array of IPTC fields.
1 call to FileSearch::getExifTagmarker()
- FileSearch::extractContentExif in src/
Plugin/ Search/ FileSearch.php - Extract IPTC metadata from image.
File
- src/
Plugin/ Search/ FileSearch.php, line 517
Class
- FileSearch
- Executes a keyword search for files against {file_managed} database table.
Namespace
Drupal\search_file_attachments\Plugin\SearchCode
protected function getExifTagmarker() {
$tagmarker = array(
'2#005' => t('Object Name'),
'2#015' => t('Category'),
'2#020' => t('Supplementals'),
'2#025' => t('Keywords'),
'2#040' => t('Special Instructions'),
'2#080' => t('By Line'),
'2#085' => t('By Line Title'),
'2#090' => t('City'),
'2#092' => t('Sublocation'),
'2#095' => t('Province State'),
'2#100' => t('Country Code'),
'2#101' => t('Country Name'),
'2#105' => t('Headline'),
'2#110' => t('Credits'),
'2#115' => t('Source'),
'2#116' => t('Copyright'),
'2#118' => t('Contact'),
'2#120' => t('Caption'),
'2#122' => t('Caption Writer'),
);
// Allow other modules to alter defined IPTC fields.
return \Drupal::moduleHandler()
->alter('search_file_attachments_exif_tagmarker', $tagmarker);
}