[Plugin: Smarter Navigation] can I add smart navigation with javascript?
-
I am trying to insert my
<?php previous_post_smart('%link', 'next'); ?>
and<?php next_post_smart('%link', 'previous'); ?>
links in-between two areas in the content section of all my single.php posts. In my template I can choose between putting these tags after all the content of before it, but not in the middle.So I tried adding the buttons with javascript using the append() function. This did not work. The buttons seem to only work when placed directly in the single.php file.
Is there anyway I can dynamically add these buttons and keep their functionality? This was the javascript (query) I was using.
$('#singleheadingdescription').append("<div id="nextPrevContainer"><span class="prev"><?php previous_post_smart('%link', 'next'); ?></span><span class="next"><?php next_post_smart('%link', 'previous'); ?></span></div> ");
https://www.ads-software.com/extend/plugins/smarter-navigation/
- The topic ‘[Plugin: Smarter Navigation] can I add smart navigation with javascript?’ is closed to new replies.