=== Auto Alt Image Meta === Contributors: pankajchopra, sweety-garg Tags: image alt, alt text, image title, seo, accessibility Requires at least: 5.8 Tested up to: 6.9 Requires PHP: 7.4 Stable tag: 1.0.2 License: GPLv2 or later License URI: [https://www.gnu.org/licenses/gpl-2.0.html](https://www.gnu.org/licenses/gpl-2.0.html) Automatically adds missing ALT and TITLE attributes to images in posts, pages, and featured images — without modifying your database. == Description == **Auto Alt Image Meta** automatically improves image accessibility and SEO by adding missing `alt` and `title` attributes at render time. The plugin works instantly after activation and does **not require you to update posts or pages**. It dynamically injects attributes only when they are missing, ensuring existing manual values are never overwritten. This approach is lightweight, safe, and matches how professional SEO and accessibility plugins operate. ### How it works * Scans images when a page is rendered * Adds ALT and TITLE **only if they are missing or empty** * Uses a smart priority system: 1. Image title (Media Library) 2. Human-readable filename (if valid) 3. Post or page title (fallback) * Ensures **unique ALT text** when multiple images exist * Also supports **Featured Images** * Makes **no database changes** ### Why this approach is recommended * No bulk updates required * No risk of data loss * Works for old and new content * SEO-safe and accessibility-friendly * Plugin can be disabled anytime without leaving permanent changes == Features == * Automatically adds missing ALT attributes * Automatically adds missing TITLE attributes * Works for images inside post/page content * Works for featured images (post thumbnails) * Smart detection to avoid hash or junk filenames * Prevents duplicate ALT text on the same page * Never overwrites existing values * No settings page required * No database writes * Lightweight and fast == Installation == 1. Upload the plugin folder to `/wp-content/plugins/` 2. Activate **Auto Alt Image Meta** 3. That’s it — no configuration needed == Frequently Asked Questions == = Does this plugin modify my posts or images permanently? = No. All changes are applied dynamically at render time. Your database remains untouched. = Will Google and screen readers see the ALT text? = Yes. ALT and TITLE attributes are present in the final HTML output. = What happens if I already set ALT text manually? = The plugin respects manual values and does nothing. = Does it work with old posts? = Yes. Existing posts automatically benefit without updates. = What if the plugin is deactivated? = Injected ALT and TITLE attributes will no longer appear, since no permanent changes are made. == Changelog == = 1.0.1 = * Initial release * Automatic frontend ALT and TITLE injection * Featured image support * Smart fallback logic with duplicate prevention == Changelog == = 1.0.2 = * Fixed PHP 8.2 deprecation warning related to mb_convert_encoding() when parsing HTML. * Improved UTF-8 handling in DOMDocument.