In the EU, it will soon be a requirement for public sector websites to have alternative text for uploaded images. However, the users of my organization are dumb to add alternative text, and I am trying to find a way to force them to do so.
The only way I have found so far is to automatically fill in the alternative text with the title of the image, which is not excellent if an image is called "shutterstock_45363627", and could encourage laziness.
Ways I can think of having them write something:
(1) Set the field & # 39; Alternative text & # 39; in & # 39; required & # 39; through the functions.php file (although I read that the default fields cannot be changed through attachment_fields_to_edit, for example).
(2) Find the "Attachment details" file in wp-admin and add a "required" attribute to the field. What is horrible, but it could work.
(3) Use a WordPress hook to verify that the alternative text is completed when configuring an image … Or verify that the alternative text contains a space, since it must be a couple of words.
However, despite the hours of searching on Google, I can't find anything online about how to do any of this. Does anyone have suggestions?