I've created an additional media field to include in some articles, and I noticed that the ALT and Title attribute for the media field can not be set to the image. I need suggestions for an override or how to implement these tags.
First, you'll need to create a separate field for the alt tag. Make a note of this and the image field's ID.
You then need to override the article layout. To do this, copy
templates\yourtemplate\html\com_content\article\default.php (where 'yourtemplate' is the name of the template you are using).
Where you want the image to appear, you should then add some code along the lines of:
echo JHTML::_('image', $this->item->jcfields->rawvalue,$this->item->jcfields->rawvalue, ["title"=>$this->item->jcfields->rawvalue]);
This code assumes that your image field has an ID of 1, and your alt and title field has an ID of 2. Just swap these numbers if not.
If this doesn't work, try adding
JLoader::register('FieldsHelper', JPATH_ADMINISTRATOR . '/components/com_fields/helpers/fields.php');
above the code, though I think this helper should already be called on the article view.
Additional validation code may be required if it is not a required field, but the above should be the basics.