Image Attributes Pro https://imageattributespro.com/ Bulk Update WordPress Image Attributes Wed, 08 Nov 2023 06:13:23 +0000 en-US hourly 1 https://wordpress.org/?v=6.3.2 Fix Missing Image Attributes https://imageattributespro.com/add-missing-image-attributes/ https://imageattributespro.com/add-missing-image-attributes/#respond Tue, 07 Nov 2023 04:23:17 +0000 https://imageattributespro.com/?p=4014 If you used the Bulk Updater of Image Attributes Pro and still have images with missing image attributes, please check the following. Is Image Attributes Pro configured to update post HTML? WordPress stores image attributes in two locations, the media library and the post HTML. By default Image Attributes Pro will update both these locations, […]

The post Fix Missing Image Attributes appeared first on Image Attributes Pro.

]]>
If you used the Bulk Updater of Image Attributes Pro and still have images with missing image attributes, please check the following.

Is Image Attributes Pro configured to update post HTML?

WordPress stores image attributes in two locations, the media library and the post HTML. By default Image Attributes Pro will update both these locations, but these can be modified in the Bulk Updater Settings.

Here is a screenshot of the setting to update post HTML. Check if that was disabled.

Choose To Update Post HTML In Bulk Updater Settings

Is the image part of your theme decoration?

If you are testing for image attributes using an SEO tool, quite often it will report all images on a page including the ones in your header and footer and icons.

Some of these might be added in the theme for decoration or to build trust (award logos, payment logos) or sometimes even be background images.

When you see such a report, check what the images actually are. If a specific image appears multiple times across pages, then that’s very likely to be part of a header or footer or sidebar. Unless these images use standard WordPress functions for images, adding image attributes automatically is not possible.

Good news is that, fixing it is often easy and your website developer should be able to help you out.

Do every image need an image attribute?

The purpose of an image attribute is two fold. From an SEO perspective, it helps search engines identify the image. You are signaling the search engine and telling them, “Hey, this image is about my cat wearing a red hoodie”.

The second aspect is accessibility. Screen readers will read out the image and assist anyone that needs it. If someone opens your website on a slow internet and if the image fails to load, the image alt text will show up in place of the image, this adding more context to the reader.

If an image on your website is purely for decoration, then the image is irrelevant for the search engine. Someone who is not seeing the image (either they are visually impaired, or the image did not load) does not care about the decorative image either.

In both these cases it’s recommended to not have any image attribute and leave an empty image title and alt text.

Tools that check for alt text does not have a way to distinguish between a relevant image and a decorative image. It’s up to you to make an informed judgement.

If you need help, please feel free to reach out to product support. Always happy to assist.

The post Fix Missing Image Attributes appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/add-missing-image-attributes/feed/ 0
How To Test Settings Before Running The Bulk Updater https://imageattributespro.com/test-bulk-updater/ https://imageattributespro.com/test-bulk-updater/#respond Tue, 07 Nov 2023 02:57:20 +0000 https://imageattributespro.com/?p=3576 The bulk updater of Image Attributes Pro is a powerful tool. Just like with power tools, using them safely and responsibly is of paramount importance. The bulk updater commits the changes to the WordPress database making them permanent. This can be intimidating, especially when managing a large website, but with a few simple precautions, you […]

The post How To Test Settings Before Running The Bulk Updater appeared first on Image Attributes Pro.

]]>
The bulk updater of Image Attributes Pro is a powerful tool. Just like with power tools, using them safely and responsibly is of paramount importance.

The bulk updater commits the changes to the WordPress database making them permanent. This can be intimidating, especially when managing a large website, but with a few simple precautions, you can optimize its use without undue concern.

Let’s take a look into all the best practices and methods to test the Image Attributes Pro bulk updater safely.

Start With A Full Database Backup

Image Attributes Pro updates image attributes in the WordPress database. Updates are made in the Media Library as well as post HTML as per your settings.

So always start with a full database backup. If you don’t have a backup solution yet, you really need to get one as a website needs both onsite and offsite backup.

Want a recommendation? WP-DBManager is a good and reliable solution that has been around for over a decade now.

Test The Bulk Updater On A Few Images

There are many ways to run the bulk updater on a single image. You could use the Test Bulk Updater button and this will update the attributes for the oldest image in the Media Library.

Test Bulk Updater Button
Test Bulk Updater button in the Bulk Updater tab of Image Attributes Pro.

Details about the image that is updated will be displayed in the Event Log on the same page.

You can also test a single image using the Update image attributes button in the Image Attributes Pro meta box in the Media Library…

Image Attributes Pro meta box in the Media Library.

… or using the meta box in the post / page / product editor.

Meta Box In Posts Pages And Products
Image Attributes Pro meta box in the Post editor.

Row actions in the media library list view, Posts, Page and Products list also let you edit one image or post or product at a time.

Update Image Attributes Row Action In Media Library
Row action displayed on hovering over an image in the Media Library.

If you wish to update multiple images, or posts / products in one go, you can make use of the Bulk Actions.

Updating multiple images using Image Attributes Pro Bulk Actions in the Media Library.

Note that the changes made during testing are permanent. It’s the Bulk Updater running on a single image at the time.

Once you are happy with the results, you can unleash the Bulk Updater on all images using the Run Bulk Updater button in the Bulk Updater tab of Image Attributes Pro.

Refer to the Getting Started section of the documentation to learn more about each of these features and more. For any further questions, feel free to reach out via the support form.

The post How To Test Settings Before Running The Bulk Updater appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/test-bulk-updater/feed/ 0
Update Image Attributes When A Post / Product Is Published or Updated https://imageattributespro.com/update-image-attributes-on-save-post/ https://imageattributespro.com/update-image-attributes-on-save-post/#respond Tue, 25 Apr 2023 06:19:07 +0000 https://imageattributespro.com/?p=3035 While working on multi author websites it can be a challenge to make sure everyone uses the same format for image attributes. Maybe you have a website where you import posts or products and you wish to keep image attributes updated to your liking. In both these cases, Image Attributes Pro can act as a […]

The post Update Image Attributes When A Post / Product Is Published or Updated appeared first on Image Attributes Pro.

]]>
While working on multi author websites it can be a challenge to make sure everyone uses the same format for image attributes.

Maybe you have a website where you import posts or products and you wish to keep image attributes updated to your liking.

In both these cases, Image Attributes Pro can act as a fallback and update image attributes when the post is published.

In Advanced settings > Miscellaneous Settings > Enabled Update image attributes on post publish or update.

Update Image Attributes When A Post Is Published

When you publish a new post or update an existing post, the image attributes of all images associated with the post will be updated as per the settings of Image Attributes Pro.

Things To Note:

  • Be mindful of the Handling existing attributes setting in the Bulk Updater Settings. If it’s set to Preserve existing attributes and add missing attributes only, then attributes added during image upload or by the user will not be overwritten when the post is published / updated.
  • Requires Image Attributes Pro version 4.3 or later.

The post Update Image Attributes When A Post / Product Is Published or Updated appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/update-image-attributes-on-save-post/feed/ 0
Backwards Compatibility https://imageattributespro.com/backwards-compatibility/ https://imageattributespro.com/backwards-compatibility/#respond Mon, 24 Apr 2023 18:58:10 +0000 https://imageattributespro.com/?p=3556 Image Attributes Pro is shipped as two packages. When both of them are installed and activated, you will find them in the Plugins list of WordPress like so: Currently both the free and pro add-on follow the same version number and are released simultaneously. i.e. version 4.x of Auto Image Attributes From Filename With Bulk […]

The post Backwards Compatibility appeared first on Image Attributes Pro.

]]>
Image Attributes Pro is shipped as two packages.

When both of them are installed and activated, you will find them in the Plugins list of WordPress like so:

Image Attributes Pro In WordPress Plugins List

Currently both the free and pro add-on follow the same version number and are released simultaneously. i.e. version 4.x of Auto Image Attributes From Filename With Bulk Updater and Image Attributes Pro are released at the same time.

Since the free version is available to everyone for free, you will be able to update it even without an active license. However, updating Image Attributes Pro requires an active license at the time of download.

When you update Auto Image Attributes From Filename With Bulk Updater to the latest version without updating Image Attributes Pro, you might see a notice like so:

Image Attributes Pro Version Combatibiltiy Notice

This is because you have Image Attributes Pro installed, but not the version required to use a particular feature.

Note: Users of Auto Image Attributes From Filename With Bulk Updater who do not have Image Attributes Pro will never see this message. The free plugin has always been and always will be usable without Image Attributes Pro.

How To Update Image Attributes Pro?

If you have an active license, simply head over to your account and download the latest version.

If your license has expired, your account dashboard will show you your renewal options and you may choose the one that best suits your needs.

For any questions or concerns, please write to me and I will be there to help you through it.

The post Backwards Compatibility appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/backwards-compatibility/feed/ 0
Copy image attributes to post HTML while updating in Media Library. https://imageattributespro.com/auto-copy-image-attributes-to-post-html-from-media-library/ https://imageattributespro.com/auto-copy-image-attributes-to-post-html-from-media-library/#respond Mon, 24 Apr 2023 12:57:50 +0000 https://imageattributespro.com/?p=3595 WordPress stores image attributes in the Media Library and in the Post HTML. Updating image attributes in the Media Library does not update the attributes stored in the post HTML by default. With Image Attributes Pro version 4.3 and later, you have the option to update the image title and image alt text in the […]

The post Copy image attributes to post HTML while updating in Media Library. appeared first on Image Attributes Pro.

]]>
WordPress stores image attributes in the Media Library and in the Post HTML. Updating image attributes in the Media Library does not update the attributes stored in the post HTML by default.

With Image Attributes Pro version 4.3 and later, you have the option to update the image title and image alt text in the post (or product) HTML when you update attributes in the Media Library.

You will find this setting in Image Attributes Pro settings > Advanced tab > Miscellaneous Settings as you can see below.

Copy Image Attributes To Post Html While Updating The Media Library

Once you enable this option, each time you update any image attribute in the Media Library, the image title and image alt text will be copied to the posts, pages or products where the image is used.

A list of posts where the image is used will be available in the Media Library meta box.

Here are few screenshots to help you understand how this feature works.

Updating Media Library With New Image Attributes
Updating image attributes in the Media Library. The meta box shows where the image is used.
Image Attributes Copied To The Post Html
Image title and alt text is copied over to the product HTML while updating Media Library.

Few things to note:

  • The image attributes are copied over only when you update the Media Library manually. When Media Library is updated programmatically, the attributes are not copied over.
  • The image attributes will be used just as they are in the Media Library. Any attribute settings you have in the Advanced tab of Image Attributes Pro will be overridden.
  • The Bulk Updater must be configured to Update in the Post HTML in the Bulk Updater Settings of Image Attributes Pro. Otherwise, the attributes will not be copied over.
  • If bulk updater is set to Preserve existing attributes and add missing attributes only, then image attributes are only copied over if the corresponding attributes are empty in the post HTML.

The post Copy image attributes to post HTML while updating in Media Library. appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/auto-copy-image-attributes-to-post-html-from-media-library/feed/ 0
Update Image Attributes In Divi Theme https://imageattributespro.com/divi-compatibility/ https://imageattributespro.com/divi-compatibility/#respond Mon, 27 Mar 2023 15:33:16 +0000 https://imageattributespro.com/?p=3478 The wildly popular Divi theme from Elegant themes comes with a versatile drag-and-drop Visual Editor called the Divi Visual Builder. This Visual Builder includes six or so image blocks that adds images. If you have a website built with Divi and if you are looking to update the attributes of all the images in bulk, […]

The post Update Image Attributes In Divi Theme appeared first on Image Attributes Pro.

]]>
The wildly popular Divi theme from Elegant themes comes with a versatile drag-and-drop Visual Editor called the Divi Visual Builder. This Visual Builder includes six or so image blocks that adds images.

Divi Visual Builder

If you have a website built with Divi and if you are looking to update the attributes of all the images in bulk, you have come to the right place. Image attributes such as image title and alt text are great for accessibility and image SEO.

Most blocks of Divi that uses image pull the image title and alt text from the Media Library. Updating image attributes in the Media Library updates them on the page.

However, for the image block (the one that is specifically designed to upload and showcase an image), Divi uses its proprietary image markup to include the image alt text and image title in the post HTML. This is similar to how WordPress does it, but in Divi’s own style.

Divi Image Module

Starting with Image Attributes Pro version 4.2, when Divi’s format is detected, Image Attributes Pro will update the image attributes within it’s proprietary format automatically.

To update all your image attributes in bulk, simply configure the Bulk Updater of Image Attributes Pro and just run the Bulk Updater. No special configuration needed.

The post Update Image Attributes In Divi Theme appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/divi-compatibility/feed/ 0
Update Image Attributes In Advanced Custom Fields (ACF) WYSIWYG Editor https://imageattributespro.com/acf-compatibility/ https://imageattributespro.com/acf-compatibility/#respond Mon, 27 Mar 2023 14:18:02 +0000 https://imageattributespro.com/?p=3479 The WYSIWYG (What You See Is What You Get) Editor of ACF can be added to various post types. Just like the WordPress classic editor, you can add images into it. Just like in the WordPress classic editor, when images are added to ACF’s WYSIWYG Editor, the image title, alt text and caption are stored […]

The post Update Image Attributes In Advanced Custom Fields (ACF) WYSIWYG Editor appeared first on Image Attributes Pro.

]]>
The WYSIWYG (What You See Is What You Get) Editor of ACF can be added to various post types. Just like the WordPress classic editor, you can add images into it.

Just like in the WordPress classic editor, when images are added to ACF’s WYSIWYG Editor, the image title, alt text and caption are stored in the post HTML. If you are confused what that means, please refer: Understanding How WordPress Store Image Attributes.

ACF WYSIWYG Editor
Text View of ACF’s WYSIWYG Editor

This editor behaves exactly like the WordPress classic editor. Updating image attributes in the media library will not automatically reflect in the WYSIWYG HTML.

How To Update Image Attributes In ACF WYSIWYG Editor In Bulk

As you can imagine, updating the image attributes of all images used in the WYSIWYG Editor is going to be a tedious job. Your interns who are eager to make a good impression will also dislike you for doing it.

Thankfully, Image Attributes Pro version 4.2 and later can help. When a WYSIWYG Editor is detected along with a post, page or any compatible post type, Image Attributes Pro bulk updater will automatically update the attributes of the images used in it.

The Bulk Updater Settings that is used for the post will be carried over to the WYSIWYG Editor. No special action or configuration is required.

The post Update Image Attributes In Advanced Custom Fields (ACF) WYSIWYG Editor appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/acf-compatibility/feed/ 0
Event Logging https://imageattributespro.com/event-log/ https://imageattributespro.com/event-log/#respond Tue, 13 Dec 2022 09:04:09 +0000 https://imageattributespro.com/?p=3214 With Image Attributes Pro 4.0 and later a log file is created to keep a log of images and posts / products updated. By default this will be in the file \wp-content\uploads\iap-logs\iap-bu-log.log. The log from this file will be displayed in the Event Log in the Bulk Updater tab of Image Attributes Pro. A .htaccess […]

The post Event Logging appeared first on Image Attributes Pro.

]]>
With Image Attributes Pro 4.0 and later a log file is created to keep a log of images and posts / products updated.

By default this will be in the file \wp-content\uploads\iap-logs\iap-bu-log.log. The log from this file will be displayed in the Event Log in the Bulk Updater tab of Image Attributes Pro.

A .htaccess file and index.html file will also be created in the \iap-logs\ folder for security reasons.

If WordPress does not have the sufficient permissions to create the folder and files, event logging will not happen. However, Image Attributes Pro will still work and update image attributes just without a log file.

Starting with version 4.4 the Event Log in the admin will display the latest 10,000 log entries. Too many lines makes WordPress UI slow and unusable. If your log file is larger than 10,000 lines, then download the log file from your server to see the complete log.

Delete Event Log File

You can delete the Event Log file from Image Attributes Pro admin using the Delete button (since version 4.1).

This button is in the Bulk Updater tab of Image Attributes Pro. Refer the screenshot below.

Delete Bulk Updater Event Log Button

You can also delete the file manually in \wp-content\uploads\iap-logs\iap-bu-log.log via FTP.

The post Event Logging appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/event-log/feed/ 0
Prevent Duplicate Image Attributes https://imageattributespro.com/prevent-duplicate-image-attributes/ https://imageattributespro.com/prevent-duplicate-image-attributes/#respond Mon, 14 Nov 2022 06:40:00 +0000 https://imageattributespro.com/?p=3137 When a post / product has multiple images, it’s possible for all the images to have the same image attribute. For example, if Image Attributes Pro is configured to use the product title as image attribute, then all images in the product will have the same product title. From a technical stand point, duplicate image […]

The post Prevent Duplicate Image Attributes appeared first on Image Attributes Pro.

]]>
When a post / product has multiple images, it’s possible for all the images to have the same image attribute.

For example, if Image Attributes Pro is configured to use the product title as image attribute, then all images in the product will have the same product title.

From a technical stand point, duplicate image attributes is not an issue for SEO. However from an accessibility / user experience stand point it is odd to have the same image attribute for all images in a post.

The most commonly asked solution for this problem is to add a count to the image attributes so each of them would be unique. With a count added the image attributes would read “product title 1”, “product title 2” and so on.

As of Image Attributes Pro version 3.2, this is quite complicated to accomplish and there is no %count% custom image attribute tag.

However, here are some ideas to solve the problem of duplicate image attributes.

Use A Different Category Name For Each Image

Image Attributes Pro comes with a custom attribute tag %category% which will add the first category name to the image attribute. If the post / product has multiple categories, this attribute tag can be modified to return a different category for each image.

To do so, add the following code into the functions.php of your active theme. This code takes advantage of the iaffpro_custom_attribute_tag_category_names filter and returns a random category name for each image.

/**
 * Return a random category name from the categories associated with a post / product.
 * This modifies the output generated by %category% custom attributes tag in Image Attributes Pro.
 * 
 * @link https://imageattributespro.com/codex/iaffpro_custom_attribute_tag_category_names/
 * 
 * @param $first_category (string) The first category available.
 * @param $categories (array) Contains the names of all categories associated with given post.
 * 
 * @return (string) A random category name.
 */
function prefix_iap_add_random_category_in_custom_attribute_tag_category( $first_category, $categories ) {

    $random_key = array_rand( $categories );

    // Return a random category.
    return $categories[$random_key];
}
add_filter( 'iaffpro_custom_attribute_tag_category_names', 'prefix_iap_add_random_category_in_custom_attribute_tag_category', 10, 2 );

Use A Different Tag Name For Each Image

Another option is to use a random tag for each image in a post / product. The default behaviour of the %tag% custom image attribute is to use the first tag name available.

This can be modified to output a random tag name from the tags used in the post / product by adding the following code to functions.php of your active theme. Here we are using the iaffpro_custom_attribute_tag_tag_names filter to return a random tag name for each image.

/**
 * Return a random tag name from the tags associated with a post / product.
 * This modifies the output generated by %tag% custom attributes tag in Image Attributes Pro.
 * 
 * @link https://imageattributespro.com/codex/iaffpro_custom_attribute_tag_tag_names/
 * 
 * @param $first_tag (string) The first tag available.
 * @param $tags (array) Contains the names of all tags associated with given post.
 * 
 * @return (string) A random tag name.
 */
function prefix_iap_add_random_tag_in_custom_attribute_tag_tag( $first_tag, $tags ) {

    $random_key = array_rand( $tags );

    // Return a random tag.
    return $tags[$random_key];
}
add_filter( 'iaffpro_custom_attribute_tag_tag_names', 'prefix_iap_add_random_tag_in_custom_attribute_tag_tag', 10, 2 );

The post Prevent Duplicate Image Attributes appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/prevent-duplicate-image-attributes/feed/ 0
Custom Image Attribute Tags https://imageattributespro.com/custom-image-attribute-tags/ https://imageattributespro.com/custom-image-attribute-tags/#comments Wed, 26 Oct 2022 10:16:38 +0000 https://imageattributespro.com/?p=3108 Image Attributes Pro lets you build your own image attributes in a modular style using any combination of the available custom image attribute tags. For example, a custom attribute like %posttitle% - %sitetitle% will become the Post / Product title - Site Title. Available Custom Attribute Tags Here are all the custom attribute tags available […]

The post Custom Image Attribute Tags appeared first on Image Attributes Pro.

]]>
Image Attributes Pro lets you build your own image attributes in a modular style using any combination of the available custom image attribute tags.

For example, a custom attribute like %posttitle% - %sitetitle% will become the Post / Product title - Site Title.

Available Custom Attribute Tags

Here are all the custom attribute tags available with Image Attributes Pro. Each of these tags will be replaced by their corresponding value when an image attribute is updated.

  • %filename% – Image filename.
  • %posttitle% – Title of the post, page or product where the image is used.
  • %sitetitle% – Site Title defined in WordPress General Settings.
  • %category% – Post or product Category. First category name will be used by default. Can be altered using iaffpro_custom_attribute_tag_category_names filter.
  • %tag% – Post or product Tag. First tag name will be used by default. Can be altered using iaffpro_custom_attribute_tag_tag_names filter.
  • %excerpt% – Post excerpt or product short description.
  • %copymedialibrary% – To copy image attributes from Media Library to the post / product HTML.
  • %imagetitle% – Image Title from the Media Library.
  • %imagealttext% – Image Alt Text from the Media Library.
  • %imagecaption% – Image Caption from the Media Library.
  • %imagedescription% – Image Description from the Media Library.

A note about %copymedialibrary%:

  • This attribute is primarily designed to copy the image attribute in the Media Library to the Post HTML. Updates in the Media Library are automatically disabled when either image title or alt text is set to be updated in the Post HTML.
  • However, it can also be used to modify the attributes in the Media Library. For example, if you wish to append your business name to all attributes, you could use %copymedialibrary% - My Business Name. Remember to disable updates in Post HTML in the Bulk Updater Settings to do so.
  • If you wish to modify attributes in the Media Library as well as Post HTML, two passes of the Bulk Updater will be required. The first pass to modify values in the Media Library alone (by disabling updates in Post HTML) and a second pass to copy the modified values in the Media Library to the Post HTML.

Dynamic Custom Tags

These custom image attribute tags are available only when corresponding plugins are enabled.

Want To Create Your Own Attribute Tags?

You can do so using the iaffpro_get_custom_attribute_tag_{%tagname%}() function. Details and an example is available in the dedicated codex entry →.

The post Custom Image Attribute Tags appeared first on Image Attributes Pro.

]]>
https://imageattributespro.com/custom-image-attribute-tags/feed/ 6