Hi, use DW Minion and cant understand how i can paste code of social links after content article and before comments. Try to use file (single.php) but it paste or in the wrong place or theme not working.
Hi,
If you want to display the social links after content article and before comments section, you can open the single.php file then add your shortcode under line 7: get_template_part( 'content', 'single' );
For Example: I have used The Social Link
plugin, after settings plugin and open the single.php add the shortcode: <?php the_social_links();?>
under line 7 in the single.php
file.
<?php
while ( have_posts() ) : the_post();
get_template_part( 'content', 'single' );
the_social_links();
dw_minion_content_nav( 'nav-below' );
dw_minion_related_post($post->ID);
if ( comments_open() ) comments_template();
endwhile;
?>
NOTE: If you still face there issue, you can tell me know which plugin are you using. I will check and help you.
Hope this helps !
noup, its not working, how i’m doing
in function.php i added code
function profit_shortcode1() {
if(is_single()){
$profit_advert = <<<HTML
<<<>>>
HTML;
return $profit_advert;
}
}
add_shortcode( ‘profit1’, ‘profit_shortcode1’ );
after i using shortcode – [social] in single.php under line 7: get_template_part( ‘content’, ‘single’ );
and article stop working 🙁
function profit_shortcode1() {
if(is_single()){
$profit_advert = <<<HTML
SOCIAL CODE HERE
HTML;
return $profit_advert;
}
}
add_shortcode( ‘profit1’, ‘profit_shortcode1’ );
Which plugin are you using?
Please login or Register to submit your answer