Codeless
  • Support Home
  • Themes
  • Support
  • WordPress Tutorials
    • How to Start a Blog
    • Best Website Builders
    • Best Small Business Hosting
    • Email Marketing Services
    • Cheap WordPress Hosting
  • Video Tutorials

Community Forums

Service Media link issue

service media
    • 10 years, 1 month ago sharonekatz
      Participant

      Expired

      Hi:

       

      Still trying to trouble shoot this issue for my client. We are using the service media box to bring in images. Overall it works fine however, our images don’t need links and there seems to be no way to disable it. I tried going into the code and simply removing the “#” and deleting the link tag placeholder but that did not work.

      So the unfortunate functionality is that if you click on the title of the image or the image itself the page refreshes and targets back up to the top which is very annoying. Is there any other way to disable this?

      You can see the behavior here: https://aquaplaysolutions.com/spray-features

      Is there a fix?

      Thank you.

    • 10 years, 1 month ago Mirela
      Participant

      Hello,

      Please go to file \vc_templates\services_media.php, and find these lines:

      if($style == 'style_1'){
         $output .= '<h5><a href="'.esc_url($link).'">'.esc_html($title).'</a></h5>';
         $output .= '<p>'.do_shortcode($content).'</p>';
      }

      Replace with these:

      if($style == 'style_1'){
         $output .= '<h5>'.esc_html($title).'</h5>';
         $output .= '<p>'.do_shortcode($content).'</p>';
      }

      Save file.

      Best regards!

    • 8 years, 9 months ago wally
      Participant

      Expired

      Hi Mihaila,

      I had the same problem in my home page, so I modified the \vc_templates\services_media.php  as you said above:

      
       if($style == 'style_1'){
                  $output .= '<h5>'.esc_html($title).'</h5>';
                  $output .= '<p>'.do_shortcode($content).'</p>';
              }
      

       

       

      This solved the problem for the text link, but the images in my home page are still clickable, I am referring to these images in my home:

      https://monosnap.com/file/ywQfYJqJcb5Wdqb2vfkWuS5upSUTZQ

      they are still embedding a link, you can see if you mouse over.

      How can I remove the image links?

      Thankss

      Home page: https://www.mybulgaria.it/

       

      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
      • This reply was modified 8 years, 9 months ago by wally.
    • 8 years, 9 months ago Mirela
      Participant

      Hello,

      The code line responsible for the images is this:

          $output .= '<a href="'.esc_url($link).'"><div class="overlay">';
                      $output .= '<img src="'.esc_url($photo).'" alt="" />';
                      $output .= '<span></span>';
                      if($style == 'style_2')
                          $output .= '<h5><a href="'.esc_url($link).'">'.esc_html($title).'</a></h5>';
                  $output .= '</div></a>';

      To remove the link effect, edit the code above to this:

      $output .= '<div class="overlay">';
                      $output .= '<img src="'.esc_url($photo).'" alt="" />';
                      $output .= '<span></span>';
                      if($style == 'style_2')
                          $output .= '<h5><a href="'.esc_url($link).'">'.esc_html($title).'</a></h5>';
                  $output .= '</div>';

      Save changes.

      Best regards!

    • 8 years, 9 months ago EngeniousDesign
      Participant

      Expired

       

      Is this an all or nothing fix?

      What if I want some of the service media images to have links and be clickable and the ones that don’t have links remain unclickable?

    • 8 years, 9 months ago Mirela
      Participant

      Hello,

      Sorry but that is not possible.
      The services are controlled by one file therefore it’s not possible for only some of them to have a different behavior.

      Best regards!

Viewing 5 reply threads

You must be logged in to reply to this topic.

Login

Log In
Register

Renew Support

  • Renew Specular Support
  • Renew Tower Support
  • Renew Folie Support
  • Renew Handel Support
  • Renew June Support
  • Renew Picante Support
  • Renew Thype Support
  • Renew Regn Support

Search Forums

Forums

  • Bygge – Construction Theme
  • Converta – Software Theme
  • Folie – The WordPress Website Builder
  • Handel – Responsive Multi-Purpose Business Theme
  • June WooCommerce WordPress Theme
  • Livecast – Podcast Theme
  • Picante – Restaurant & Food WordPress Theme
  • Regn | Agency & Business WordPress Theme
  • Remake – Minimal Portfolio & Agency Theme
  • Specular – Multi-Purpose WordPress Theme
  • Suggest us Features
  • Tower – Business-Driven Multipurpose WP Theme
  • Vibrance – Photography Theme

Site Links

  • Support Policy
  • Specular Support Forum
  • Video Tutorials
  • Knowledge Base
  • Guides and Reviews

Useful Articles

  • Build a Website
  • Web Design & Development
  • Hosting
  • WordPress

Login

Log In
Register Lost Password