Hi,
I have a strange error. I have four portfolio entries. On every page I have a masonry with the portfolios. If I click on the portfolio, it opens in a new window. It should not open blank but inside the same window. Any advices, I do not realy understand this.
Thank you Barbara
The link: http://s338144659.online.de/fliegenfischen-gewaesser/fliegenfischen-ischler-traun/
Hey weblinedesign,
Did you add some custom code that allows it to open in new tab?
Normally it doesn’t doesn’t open in new tab by default.
Best regards,
Nikko
Hi Nikko,
thank you for taking a look. No, there is no custom code inside.
I saw, when I include Portfolio raster it is opened in the same window. But when I include a masonry, it is opened in a new window?
Maybe you can take a look a look.
Thank you and best regards
Barbara
Hi weblinedesign,
Thanks for giving us admin access.
I can see this code in your child theme’s functions.php:
function add_custom_target(){
?>
<script>
jQuery(window).load(function(){
jQuery('.av-masonry-container a ').attr('target','_blank');
});
</script>
<?php
}
add_action('wp_footer', 'add_custom_target');
I tried to remove it in Appearance > Editor however I’m prevented to do the action.
Please remove that code and that should fix it.
Best regards,
Nikko
Hi Nikko,
thank you so much for your help. This was the error. I don’t know, how this could happen :((
Maybe I tried something and did nor remember. Sorry for the inconvinience.
Now everything is ok.
Happy holidays
Barbara
Hi Barbara,
Glad that we could help you :)
Thanks for using Enfold and Advance Merry Christmas!
Best regards,
Nikko