if there is a previous or next post then the markup will show. You can manipulate this as needed.
For related posts, related how? by topic? all topics. one topic?
For all topics you will need to loop through your blogs and compare their topics to the current post's topics. If your only matching one topic you can use this function:
{% set topic_posts = blog_recent_topic_posts('default', 'marketing-tips', 5) %}
{% for topic_post in topic_posts %}
<div class="post-title">{{ topic_post.name }}</div>
{% endfor %}
where marketing-tips is the topic. You can set this up to a text or choice module value by using export_to_template_context.
That's all the HubL you need. The rest of your question is javascript.
Does this section popup or does it become visible on scroll? these things are different. If it is popup then you will want to look for popup scripts, of you just want it to become visible on scroll then checkout waypoint.js.
Well first your missing your quotations around the href value.
Second, if .name outputs the post name and an href expects a url... .name wont work. I would consider trying a token that outputs a url like .absolute_url if that is the correct syntax. All variables can be found in the variable section of the hubl docs. Dont forget your quotations.
if there is a previous or next post then the markup will show. You can manipulate this as needed.
For related posts, related how? by topic? all topics. one topic?
For all topics you will need to loop through your blogs and compare their topics to the current post's topics. If your only matching one topic you can use this function:
{% set topic_posts = blog_recent_topic_posts('default', 'marketing-tips', 5) %}
{% for topic_post in topic_posts %}
<div class="post-title">{{ topic_post.name }}</div>
{% endfor %}
where marketing-tips is the topic. You can set this up to a text or choice module value by using export_to_template_context.
That's all the HubL you need. The rest of your question is javascript.
Does this section popup or does it become visible on scroll? these things are different. If it is popup then you will want to look for popup scripts, of you just want it to become visible on scroll then checkout waypoint.js.
Well first your missing your quotations around the href value.
Second, if .name outputs the post name and an href expects a url... .name wont work. I would consider trying a token that outputs a url like .absolute_url if that is the correct syntax. All variables can be found in the variable section of the hubl docs. Dont forget your quotations.