Hello, I am using the catalogue element (I think I am using a modified version of it because it is called car gallery in the content elements menu)
I have selected the option for adding a link and then when I select open link in same window it still opens in a new window
Hey B,
Sorry for the late reply, this sounds like a custom element because we don’t have a “car gallery”
But assuming that they are created the same on all pages, Try adding this code to the end of your functions.php file in Appearance > Editor:
function target_custom_script(){
?>
<script>
(function($){
$(document).ready(function(){
$('.av-car-catalogue-wrap a.btn.btn-white-border[target="_blank"]').removeAttr('target');
});
})(jQuery);
</script>
<?php
}
add_action('wp_footer', 'target_custom_script');
Then check all of your pages for conflicts, it would be better if you could add a custom class to these so there would be no chance of conflicts.
Best regards,
Mike