I was focused too much on the front-end. We could fix it on the back-end by reordening or deleting and reuploading the images.
You can close the topic.
Thanks! It’s working in three languages now.
I had to check the names of the slugs in the other languages, add them for the other languages (I had to add them for the other languages, although you would expect these to be included automatically) and resave the pages.
I used this code:
add_filter('avf_ratio_check_by_tag_values', 'avf_ratio_check_by_tag_values_mod', 10, 1);
function avf_ratio_check_by_tag_values_mod($tags) {
$lang = ICL_LANGUAGE_CODE;
if($lang == 'en') $tags = array('portrait' => 'portrait', 'landscape' => 'landscape');
if($lang == 'nl') $tags = array('portrait' => 'portrait-nl', 'landscape' => 'landscape-nl');
if($lang == 'fr') $tags = array('portrait' => 'portrait-fr', 'landscape' => 'landscape-fr');
return $tags;
}
