Disable Link in Portfolio

Hello,

i’ve just created a portfolio and it works fine for me.
i only what to know how to prevent opening a new site whenever someone klicks on the image?
The blue hovereffect is okay. i just dont want to open the image.

i hope you understand what i mean.

www.zeki-hairdesign.de

thanks

Hello there,

There is no such that option by default. You can achieve it by using custom jQuery code. Please follow the below steps:

  1. Install and activate the TC Custom JavaScript plugin
  2. Go To Appearance > Custom JavaScript
  3. Paste the following code into the provided box

jQuery(function($) {
    $('.project-item').each( function() {
           
      var link =  $(this).find('a');
    
      link.attr('href', '#');

      link.on('click',function (e){
        e.preventDefault();
      });      
	
    });
});

  1. Update

Regards,
Kharis

wow, cool :slight_smile:

thank you!

You’re welcome.

Please let us know in a new topic if you have any further questions, or if we can provide you with any other assistance.

Regards,
Kharis