Dynamic Section layout on Blog posts.

stv
Tourist
6 0 3

Hi All,

I know that this has probably been discussed a million times but I still can't find an easy solution to this. 🙂

I would like to be able to reference an existing section (hero.liquid for example) and use it for a page or use in a blog post, but when I define this in the theme editor it only allows me to define it once and not customize it per blog post?

Do I need to customize the storage location for the meta-data associated with each blog post. Where is this stored? section id=??? data-section-id=??? 🙂 Please Help.

Using Section in Template file (page.dynamic.liquid)

<section class="page">
<div class="wrapper">
<div class="content-container narrow rte">
{% section 'hero' %}
{{ page.content }}
</div>
</div>
</section>

 

Cheers,

Steve

 

Replies 11 (11)

KetanKumar
Shopify Partner
36839 3635 11972

@stv 

Sorry for facing this issue, it's my pleasure to help us.

Welcome to the Shopify community!
and Thanks for your Good question. 😊

Please share your site URL,
So I will check and provide a solution here.

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
stv
Tourist
6 0 3

Hi KetanKumar,

Thanks for responding about dynamic sections on pages and posts. This is a generic question that I would like to apply to a number of stores so I don’t know why you need a link to website, but my Development website is skullindesign.com

let me know if you have example code or describe how you would solve such an issue. 

I appreciate any assistance.

Thanks,

Steve

 

KetanKumar
Shopify Partner
36839 3635 11972

@stv 

yes can you please create new section  and add this page that's is 

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
stv
Tourist
6 0 3

Hi, The pages are created at:

https://www.skullindesign.com/pages/section_page1

https://www.skullindesign.com/pages/section_page2

Screen Shot 2021-02-01 at 11.37.33 AM.png

If you look at this code, how do I specify the data-section-id? it defaults to hero but on main page it has a GUID generated number for each section?

thanks,

Steve 

KetanKumar
Shopify Partner
36839 3635 11972

@stv 

great

 can you please other section as you like

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
stv
Tourist
6 0 3

In responds to " great can you please other section as you like"

Can you repeat what you want me to do? I don't understand what you are saying.

thanks,

Steve

KetanKumar
Shopify Partner
36839 3635 11972

@stv 

do you need multiple sections on the custom page?

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
stv
Tourist
6 0 3

Yes, thanks ... multiple selections would be great!

KetanKumar
Shopify Partner
36839 3635 11972

@stv 

Thanks for confirm 

please try this 

http://www.codeshopify.com/blog_posts/shopify-sections-with-dynamic-blocks

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
stv
Tourist
6 0 3

Thanks for the link, that is a way to create multiple snippets on a page but I was looking for a way to re-use the default sections instead of creating a new section or snippet file for each use.

As I want to use sections to format each blog post. 

i appreciate your help. 

cheers,

steve

KetanKumar
Shopify Partner
36839 3635 11972

@stv 

Yes, please try it's easy for your add multi-block same as home page

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing