- This topic has 6 replies, 4 voices, and was last updated 9 years, 1 month ago by Theme Horse Support Team.
-
AuthorPosts
-
March 11, 2015 at 3:29 pm #22996guitaristforhimParticipant
Hi,
I have started adding the slider, but I don’t want visitors to be able to click the Slider image and go to the post page. Is there any way I can remove the link and just make it an image?
ThanksMarch 12, 2015 at 5:08 am #23009Theme Horse Support TeamKeymasterHi guitaristforhim,
You need code customisation for it. You just simply go to the theme folder(interface)-> inc -> structure -> header -extension.php
Can you see this code
if( has_post_thumbnail() ) { $interface_featured_post_slider .= '<figure><a href="' . get_permalink() . '" title="'.the_title('','',false).'">'; $interface_featured_post_slider .= get_the_post_thumbnail( $post->ID, $slider_size, array( 'title' => esc_attr( $title_attribute ), 'alt' => esc_attr( $title_attribute ), 'class' => 'pngfix' ) ).'</a></figure>'; } if( $title_attribute != '' || $excerpt !='' ) { $interface_featured_post_slider .= ' <article class="featured-text">'; if( $title_attribute !='' ) { $interface_featured_post_slider .= '<div class="featured-title"><a href="' . get_permalink() . '" title="'.the_title('','',false).'">'. get_the_title() . '</a></div><!-- .featured-title -->'; } if( $excerpt !='' ) { $interface_featured_post_slider .= '<div class="featured-content">'.$excerpt.'</div><!-- .featured-content -->'; } $interface_featured_post_slider .= ' </article><!-- .featured-text -->'; }
remove this code and add this code
if( has_post_thumbnail() ) { $interface_featured_post_slider .= '<figure><a href="#" title="'.the_title('','',false).'">'; $attitude_featured_post_slider .= get_the_post_thumbnail( $post->ID, $slider_size, array( 'title' => esc_attr( $title_attribute ), 'alt' => esc_attr( $title_attribute ), 'class' => 'pngfix' ) ).'</a></figure>'; } if( $title_attribute != '' || $excerpt !='' ) { $interface_featured_post_slider .= ' <article class="featured-text">'; if( $title_attribute !='' ) { $interface_featured_post_slider .= '<div class="featured-title"><a href="#" title="'.the_title('','',false).'">'. get_the_title() . '</a></div><!-- .featured-title -->'; } if( $excerpt !='' ) { $interface_featured_post_slider .= '<div class="featured-content">'.$excerpt.'</div><!-- .featured-content -->'; } $interface_featured_post_slider .= ' </article><!-- .featured-text -->'; }
We recommended not to change the code because if you change the code then while updating to our new version all your customisation code will be lost. So better make child theme and first unhook the functions and the edit the code.
http://codex.wordpress.org/Child_Themes
Thank you!
October 9, 2015 at 11:29 am #36459ManuelParticipantmuch easier:
.featured-title { pointer-events: none; cursor: default; }
October 10, 2015 at 10:29 pm #36486info110ParticipantI just tried the below and it didn’t work.
.featured-title {
pointer-events: none;
cursor: default;
}October 11, 2015 at 2:33 am #36488info110ParticipantI played with the custom css and made it work by changing title to slider.
.featured-slider {
pointer-events: none;
cursor: default;
}October 12, 2015 at 10:48 am #36531ManuelParticipantI can’t tell you why it doesn’t work for you. For me it works perfectly fine with the Ambition Pro template.
you may just try to replace the
' . get_permalink() . '
with a#
ib the html file, as suggested by the support.October 14, 2015 at 5:58 am #36611Theme Horse Support TeamKeymasterHi info110,
We have already posted a solution on post #23009 to remove the slider link. You can create a child theme and then customize the code. If you are unable to change it then you need to hire a developer to fix it.
Thank you!
-
AuthorPosts
- You must be logged in to reply to this topic.