New Landing How can we help? Themeforest Theme Support Dante Move Next/Previous Post Button

Viewing 9 posts - 1 through 9 (of 9 total)
  • Posted in: Dante
  • #41670
    Petercity
    Member
    Post count: 107

    Hi,

    I would like to move the Next/Previous Post bloc below the social share button bloc in a blog post.

    I assume that I should modify some line in “single.php”, but as i’am very new in php could you indicate me exactly what bloc of line i should move and where to put it back.

    In case I could use the child theme, could give a documentation link to know I to use it.

    Thanks.

    #42181
    Swift Ideas – Ed
    Keymaster
    Post count: 15264

    Hi there,

    If you upload the single.php to the dante-child theme. You’ll want to move lines 228-231:

    <ul class="post-pagination-wrap curved-bar-styling clearfix">
    					<li class="prev"><?php next_post_link('%link', __('<i class="ss-navigateleft"></i> <span class="nav-text">%title</span>', 'swiftframework'), FALSE); ?></li>
    					<li class="next"><?php previous_post_link('%link', __('<span class="nav-text">%title</span><i class="ss-navigateright"></i>', 'swiftframework'), FALSE); ?></li>
    				</ul>

    to above line 268:

    <?php if ($show_social) { ?>

    Hope that helps.

    – Ed

    #42245
    Petercity
    Member
    Post count: 107

    Sorry Ed,

    I try but it didn’t work. I also try to delete the mentioned line and flush my cache, but it still appear.

    #42593
    Petercity
    Member
    Post count: 107

    Please, any idea Ed ?

    #42861
    Tahir – SUPPORT
    Member
    Post count: 1212

    Hi,
    You dont have to delete any line, Just move the code block from above to below. If you have deleted any line it could be the reason why its not working.

    Thanks
    Tahir

    #47109
    Petercity
    Member
    Post count: 107

    Hi Tahir,

    Since the hack you provide me seems to doesn’t work, I back to you because I still want to move the Move Next/Previous post below the share box.

    I just upgrade to version Dante 2.01, could indicate me the exact bloc of line to move and where to place it. Please If It’s work for you can send me the whole single.php modified code, so I can make any mistake.

    Hope to hear you soon.

    Regards.

    #48245
    Melanie – SUPPORT
    Member
    Post count: 11032

    You just take the code Ed mentioned

    <ul class="post-pagination-wrap curved-bar-styling clearfix">
    					<li class="prev"><?php next_post_link('%link', __('<i class="ss-navigateleft"></i> <span class="nav-text">%title</span>', 'swiftframework'), FALSE); ?></li>
    					<li class="next"><?php previous_post_link('%link', __('<span class="nav-text">%title</span><i class="ss-navigateright"></i>', 'swiftframework'), FALSE); ?></li>
    				</ul>

    copy it, delete it, and paste it below this bunch of code

    <?php if ($show_social) { ?>
    					<div class="share-links curved-bar-styling clearfix">
    						<div class="share-text"><?php _e("Share this article:", "swiftframework"); ?></div>
    						<ul class="social-icons">
    							<li class="sf-love">
    							<div class="comments-likes">
    							<?php if (function_exists( 'lip_love_it_link' )) {
    								echo lip_love_it_link(get_the_ID(), '<i class="ss-heart"></i>', '<i class="ss-heart"></i>', false);
    							} ?>				
    							</div>
    							</li>
    						    <li class="facebook"><a href="http://www.facebook.com/sharer.php?u=<?php the_permalink(); ?>" class="post_share_facebook" onclick="javascript:window.open(this.href,
    						      '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=220,width=600');return false;"><i class="fa-facebook"></i><i class="fa-facebook"></i></a></li>
    						    <li class="twitter"><a href="https://twitter.com/share?url=<?php the_permalink(); ?>" onclick="javascript:window.open(this.href,
    						      '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=260,width=600');return false;" class="product_share_twitter"><i class="fa-twitter"></i><i class="fa-twitter"></i></a></li>   
    						    <li class="googleplus"><a href="https://plus.google.com/share?url=<?php the_permalink(); ?>" onclick="javascript:window.open(this.href,
    						      '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600');return false;"><i class="fa-google-plus"></i><i class="fa-google-plus"></i></a></li>
    						    <li class="pinterest"><a href="http://pinterest.com/pin/create/button/?url=<?php the_permalink(); ?>&media=<?php if(function_exists('the_post_thumbnail')) echo wp_get_attachment_url(get_post_thumbnail_id()); ?>&description=<?php echo get_the_title(); ?>"><i class="fa-pinterest"></i><i class="fa-pinterest"></i></a></li>
    							<li class="mail"><a href="mailto:?subject=<?php the_title(); ?>&body=<?php echo strip_tags(get_the_excerpt()); ?> <?php the_permalink(); ?>" class="product_share_email"><i class="ss-mail"></i><i class="ss-mail"></i></a></li>
    						</ul>						
    					</div>					
    					<?php } ?>
    

    and above this code

    <?php if ($show_author_info) { ?>

    Cheers

    #49232
    Petercity
    Member
    Post count: 107

    Hi Melanie,

    Yes it works, but as the block it’s stick with the share box, how can I add a extra padding on the top of Next/Prev box ?

    Cheers

    #49237
    Swift Ideas – Ed
    Keymaster
    Post count: 15264

    Add the following custom css to add spacing:

    .article-body-wrap .share-links {
    margin-bottom: 30px;
    }

    Hope that helps.

    – Ed

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in and have valid license to reply to this topic.

License required for the following item
Login and Registration Log in · Register