--
Hippo Community Group: The place for all discussions and announcements about Hippo CMS (and HST, repository etc. etc.)
To post to this group, send email to hippo-community@googlegroups.com
RSS: https://groups.google.com/group/hippo-community/feed/rss_v2_0_msgs.xml?num=50
---
You received this message because you are subscribed to the Google Groups "Hippo Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hippo-community+unsubscribe@googlegroups.com.
Visit this group at https://groups.google.com/group/hippo-community.
For more options, visit https://groups.google.com/d/optout.
--Thanks,
Hippo Community Group: The place for all discussions and announcements about Hippo CMS (and HST, repository etc. etc.)
To post to this group, send email to hippo-community@googlegroups.com
RSS: https://groups.google.com/group/hippo-community/feed/rss_v2_0_msgs.xml?num=50
---
You received this message because you are subscribed to the Google Groups "Hippo Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hippo-community+unsubscribe@googlegroups.com.
Visit this group at https://groups.google.com/group/hippo-community.
For more options, visit https://groups.google.com/d/optout.
On Tue, Feb 20, 2018 at 8:31 AM, Vivek <vivek....@gmail.com> wrote:Hi,I have the below URL string say /level1/level2/level3/_________________Now I need to get the sub-string till level 3. i.e. /level1/level2/level3 . How can I achieve it?<#assign s="/level1/level2/level3/a/b/c.html"><#assign res=s?matches(r"^(\/[^\/]+){3}(.*)$")><#assign remaining=""><#if res><#assign remaining=res?groups[1]>
On Tue, Feb 20, 2018 at 10:56 AM, Woonsan Ko <woons...@bloomreach.com> wrote:On Tue, Feb 20, 2018 at 8:31 AM, Vivek <vivek....@gmail.com> wrote:Hi,I have the below URL string say /level1/level2/level3/_________________Now I need to get the sub-string till level 3. i.e. /level1/level2/level3 . How can I achieve it?<#assign s="/level1/level2/level3/a/b/c.html"><#assign res=s?matches(r"^(\/[^\/]+){3}(.*)$")><#assign remaining=""><#if res><#assign remaining=res?groups[1]>Sorry, it should be 'res?groups[2]'.Woonsan
</#if>${remaining} <#-- "/a/b/c.html" -->Regards,WoonsanReferences:
Thanks,
--
Hippo Community Group: The place for all discussions and announcements about Hippo CMS (and HST, repository etc. etc.)
To post to this group, send email to hippo-c...@googlegroups.com
RSS: https://groups.google.com/group/hippo-community/feed/rss_v2_0_msgs.xml?num=50
---
You received this message because you are subscribed to the Google Groups "Hippo Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hippo-communi...@googlegroups.com.
Visit this group at https://groups.google.com/group/hippo-community.
For more options, visit https://groups.google.com/d/optout.
--
To post to this group, send email to hippo-community@googlegroups.com
RSS: https://groups.google.com/group/hippo-community/feed/rss_v2_0_msgs.xml?num=50
---
You received this message because you are subscribed to the Google Groups "Hippo Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hippo-community+unsubscribe@googlegroups.com.
Visit this group at https://groups.google.com/group/hippo-community.
For more options, visit https://groups.google.com/d/optout.