Forum Discussion
kiettuongwork
Contributor
I also tried as below code in component recent-blog-posts
<#assign url = http.request.url />
<#assign parts = url?split("/") />
<#assign category = parts[(parts?size)-1] />
Hello category ${category}
You can see result at
https://communitystg.digi.com.my/t5/Blog/bg-p/11112222
Hello category = recent-blog-posts?render_behavior=raw&page=1
It should be Hello category = 11112222
Could you please advise how to retrieve 11112222?
Thanks
VikasB
7 years agoBoss
1. Add below line in a custom component https://prnt.sc/j14dzs
<#assign Blog_id = coreNode.id />
Blog id = ${Blog_id}
2. Add the component on blog page https://prnt.sc/j14ehe
3. Check the value on the blog page https://prnt.sc/j14df3
Related Content
- 7 years ago
- 9 years ago