Is there a variable modifier that works like a XPath's substring-after?

Is there a variable modifier that works like XPath's substring-after?

For instance, the substring-after function returns a string that is the rest of a given string after a given substring.


arguments in the substring function

The string to be evaluated. Part of this string will be returned.

The substring to search for. Everything after the first occurence of needle in haystack will be returned.

XPath Example and Output

Example: substring-after('aa-bb','-')

Output: bb


I would like to do the following...

I would like to get the domain name from an email address, is there a variable modifier that would allow me to target @ and get the string after the @?

So in XPath, substring-after('[email protected]','@') which would return

Is there anything in Statamic that does this?

>>>>>>> Unanswered <<<<<<<
4 Replies