Prerequisites
- Any Media Library Organizer Pro license
Overview
Settings are used to:
- Define the default attributes to apply to newly uploaded files, when no attributes are specified
- Determine the default Attachment Display Settings when inserting Media into Pages, Posts and Custom Post Types
In the WordPress Administration interface, click on Media Library Organizer > Settings
Enabling Defaults
Clicking the Defaults tab allows you to define the following settings:
For Default attributes to be applied to items uploaded to the Media Library, select Enabled from the Enabled option.
File Types
Once enabled, horizontal, secondary level file type tabs are then displayed:
Clicking one of these file type tabs allows you to define one or more rulesets of default attributes to apply to files uploaded that match the given file type, which meet one or more specified rules.
For example, you might have two rulesets:
- The first ruleset, which categorizes the uploaded file to the Screenshot category whenever the filename contains the word screenshot
- A second ruleset, which applies a default title and alt text.
Other File Types
When uploading a file type that doesn’t have its own defaults, the Other tab provides default attributes that can be defined for these files.
Simple Defaults
To apply default attributes to all files uploaded for a given file type, complete the following:
- Attributes
- Alternative Text (Alt Tag): Assigns the specified Alternative Text (known as the Alt Tag) to Images files uploaded to the Media Library, where no Alt Tag is specified with the upload.
- Title: Assigns the specified Title to Images files uploaded to the Media Library, where no Title is specified with the upload.
- Caption: Assigns the specified Caption to Images files uploaded to the Media Library, where no Caption is specified with the upload.
- Description: Assigns the specified Description to Images files uploaded to the Media Library, where no Description is specified with the upload.
- Media Categories: Assigns the specified Media Categories to Image files uploaded to the Media Library, where no Media Categories were specified with the upload.
- Rules
- Set to Ignore Rules (just apply Attributes)
Taxonomy Defaults
If you’ve added additional Taxonomies through the Taxonomy Manager, they’ll be displayed below the Media Categories field:
EXIF Defaults
Fields will be displayed for each ruleset, with the option to apply default attributes to EXIF fields, such as the Camera Make and Model:
IPTC Defaults
Fields will be displayed for each ruleset, with the option to apply default attributes to IPTC fields, such as the Copyright Notice and Web Statement of Rights:
Dynamic Tags
For the Attributes, excluding Media Categories, you’ll see an option to insert tags.
Tags are dynamic, can be used in an attribute, and will be replaced by the file’s information – for example, using {file_dimensions} will output the Image Width and Height as part of the attribute’s value.
To insert a tag, either:
- Select the tag from the dropdown list next to the Attribute field
- Start typing in the Attribute field, and click the applicable Tag from the list
There’s no limit to the number of Dynamic Tags that you use in an Attribute’s value.
The following Dynamic Tags are supported:
Name | Tag | Description | Example |
---|---|---|---|
File Name | {file_name} | The File Name | my-filename.jpg |
File Name, Prettified | {file_name_prettified} | File Name, with underscores and dashes replaced by spaces. Each word then has its first character converted to uppercase. | My Filename |
File Extension | {file_extension} | File Extension | jpg |
File Type | {file_type} | File Type | image |
File Extension and Type | {file_mime} | File Extension and Type, separated by a forwardslash | image/jpg |
File Size | {file_size} | File Size, denoted with either kb, mb, gb appended to it | 600kb |
Image Width and Height | {image_width_height} | Image Width and Height, with the word pixels appended to it | 1024 by 768 pixels |
Image Width | {image_width} | Image Width, with the word pixels appended to it | 1024 pixels |
Image Height | {image_height} | Image Height, with the word pixels appended to it | 768 pixels |
Uploaded Date | {uploaded_date} | The date when the file was uploaded, using the Date format specified at WordPress Admin > Settings > General > Date Format | July 29, 2020 |
Uploaded Time | {uploaded_time} | The date when the file was uploaded, using the Date format specified at WordPress Admin > Settings > General > Date Format | 3:54pm |
Uploaded Date and Time | {uploaded_date_time} | The date and time when the file was uploaded, using the Date format specified at WordPress Admin > Settings > General > Date Format | July 29, 2020 3:54pm |
Dynamic Tags: EXIF and IPTC
For images that might contain EXIF and/or IPTC data, the following additional Dynamic Tags are supported:
Name | Tag |
---|---|
EXIF: Camera Make | {exif_camera_make} |
EXIF: Camera Model | {exif_camera_model} |
EXIF: Created Date | {exif_created_date} |
EXIF: Created Time | {exif_created_time} |
EXIF: Author | {exif_author} |
EXIF: Comments | {exif_comments} |
EXIF: Description | {exif_description} |
EXIF: Title | {exif_title} |
EXIF: Latitude | {exif_latitude} |
EXIF: Longitude | {exif_longitude} |
EXIF: Aperture | {exif_aperture} |
EXIF: Focal Length | {exif_focal_length} |
EXIF: ISO | {exif_iso} |
EXIF: Orientation | {exif_orientation} |
EXIF: Shutter Speed | {exif_shutter_speed} |
EXIF: Flash | {exif_flash} |
EXIF: Metering Mode | {exif_metering_mode} |
EXIF: White Balance | {exif_white_balance} |
IPTC: City (legacy) | {iptc_city} |
IPTC: Copyright Notice | {iptc_copyright_notice} |
IPTC: Country (legacy) | {iptc_country} |
IPTC: Country Code (legacy) | {iptc_country_code} |
IPTC: Creator | {iptc_creator} |
IPTC: Creator’s Job Title | {iptc_creator_job_title} |
IPTC: Credit Line | {iptc_credit} |
IPTC: Date Created | {iptc_date_created} |
IPTC: Description | {iptc_description} |
IPTC: Description Writer | {iptc_description_writer} |
IPTC: Headline | {iptc_headline} |
IPTC: Instructions | {iptc_instructions} |
IPTC: Intellectual Genre Line | {iptc_intellectual_genre} |
IPTC: Job ID | {iptc_job_id} |
IPTC: Keywords | {iptc_keywords} |
IPTC: Province or State (legacy) | {iptc_state} |
IPTC: Rights Usage of Terms | {iptc_rights_usage_terms} |
IPTC: Source | {iptc_source} |
IPTC: Subject Code | {iptc_subject_code} |
IPTC: Sublocation (legacy) | {iptc_sublocation} |
IPTC: Title | {iptc_title} |
IPTC: Contact Information: Address | {iptc_contact_information_address} |
IPTC: Contact Information: City | {iptc_contact_information_city} |
IPTC: Contact Information: Country | {iptc_contact_information_country} |
IPTC: Contact Information: Email | {iptc_contact_information_email} |
IPTC: Contact Information: Postal Code | {iptc_contact_information_postal_code} |
IPTC: Contact Information: State/Province | {iptc_contact_information_state} |
IPTC: Contact Information: URL | {iptc_contact_information_url} |
IPTC: Copyright Owner: URL | {iptc_copyright_owner_id} |
IPTC: Copyright Owner: Name | {iptc_copyright_owner_name} |
IPTC: Image Creator: URL | {iptc_image_creator_id} |
IPTC: Image Creator: Name | {iptc_image_creator_name} |
IPTC: Licensor: ID | {iptc_licensor_id} |
IPTC: Licensor: Name | {iptc_licensor_name} |
IPTC: Licensor: URL | {iptc_licensor_url} |
IPTC: Web Statement of Rights / Copyright Info URL | {iptc_web_statement_of_rights} |
Conditional Defaults
To conditionally apply default attributes to all files uploaded for a given file type, based on the uploaded file’s criteria, complete the following:
- Attributes
- Alternative Text (Alt Tag): Assigns the specified Alternative Text (known as the Alt Tag) to Images files uploaded to the Media Library, where no Alt Tag is specified with the upload.
- Title: Assigns the specified Title to Images files uploaded to the Media Library, where no Title is specified with the upload.
- Caption: Assigns the specified Caption to Images files uploaded to the Media Library, where no Caption is specified with the upload.
- Description: Assigns the specified Description to Images files uploaded to the Media Library, where no Description is specified with the upload.
- Media Categories: Assigns the specified Media Categories to Image files uploaded to the Media Library, where no Media Categories were specified with the upload.
- Rules
- Set to either:
- All Rules must Pass: All rules specified below must be met for the above attributes to be applied to the uploaded file type
- Any Rule can Pass: Any single rule specified below must be met for the above attributes to be applied to the uploaded file type. It doesn’t matter if some rules fail; only one has to pass for the attributes to be applied.
- Rules:
- Alternative Text (Alt Tag): Compare the value of the Alt Tag to the supplied value
- Title: Compare the value of the Title to the supplied value
- Caption: Compare the value of the Caption to the supplied value
- Description: Compare the value of the Description to the supplied value
- Filename: Compare the value of the filename to the supplied value
- Set to either:
Multiple Rulesets
More than one ruleset can be defined for each file type. For example, you might have the following rulesets for images:
- The first ruleset, which categorizes the uploaded file to the Screenshot category whenever the filename contains the word screenshot
- A second ruleset, which defines the image title whenever the filename
- A third ruleset, which applies a default title and alt text.
Multiple rulesets are run through in order until a ruleset’s rules are met, so they are ideal for defining different rules and attributes depending on the files that are uploaded.
Add Ruleset
To define multiple rulesets:
- Click the Add Ruleset button
- Define the Attributes and Rules as necessary
Delete Ruleset
To delete an existing ruleset:
- Click the trash can button next to the number for the ruleset:
Attachment Display Settings
Below the Defaults section, options are provided to define the default values to use for the Attachment Display Settings, which are displayed in the Media modal when inserting media or files into a Page, Post or Custom Post Type:
For example, to define the default Attachment Display Settings for Images, complete the following:
[]
- Alignment: The default alignment option to preselect in the above Media Modal when an Image is selected to be inserted into content.
- Link To: The default link to option to preselect in the above Media Modal when an Image is selected to be inserted into content.
- Size: The default image size option to preselect in the above Media Modal when an Image is selected to be inserted into content.
Save
Once you have made changes to the settings, click the Save button.
On screen confirmation will display to confirm that the settings have been updated.