- This topic has 3 replies, 3 voices, and was last updated 8 years, 11 months ago by Theme Horse Support Team.
-
AuthorPosts
-
March 1, 2015 at 9:22 pm #22626julie.pettParticipant
Hello, How do I remove the url links to the post page from my slider images on the front page? A solution was posted for the Attitude theme (https://www.themehorse.com/support-forum/topic/removing-link-in-slider/) but I couldn’t follow it or find how to locate theme folder -> library -> structure -> header -extension.php
March 2, 2015 at 5:19 am #22632Theme Horse Support TeamKeymasterHi julie.pett,
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 -->'; }
From here you slider and all content is displayed but 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!
January 29, 2016 at 8:59 pm #42008CucerescuParticipantHi,
I want to remove the links from slider image but i cannot find that code from the above.
Also the filename is header-extensions.php instead of header-extension.php
Is this possible? interface pro 3.0.2February 1, 2016 at 10:53 am #42080Theme Horse Support TeamKeymasterHi Cucerescu,
Yes the file name is header-extension.php, You need to find that above code and remove the<a> tag
from that image. There are two slider in interface pro. Featured post/ page image slider and Upload Image slider. First make confirm that which slider are you using. Go throughline no 521
there you can find the slider image code and alsoline no 589 to 593
From there you may remove the
<a> tag
Note: Before making changes in the code first create a child theme then only customize the code. So that while updating to new version your customized code will not be lost. Other wise if you update to new version each and every time you need to make same code customization.
Thank you!
-
AuthorPosts
- You must be logged in to reply to this topic.