Forum Documentation Showcase Pricing Learn more

Quick regex extract for first and last name

Hi Guys,

Just a quick tip for extracting the first and last name with a regex pattern using the :item expression.


Regex pattern: ([^\s]+)

Demo:
extract-names

Conditions could be used if the person just enters a first name or even if they enter a middle name…

Cheers

3 Likes

So many tips we continue to discover, even after so long! Great, thank you.

2 Likes

Thanks @JohnMark

So many possibilities with regex expressions.

2 Likes

For basic checking middle name or outputting dynamic content based on the input of the user, a condition such as this could also be beneficial:


extract-names-middle
Using :count or could use is empty to evaluate result

1 Like

Luke, if we wait a little longer, you’il uncover our genealogy🤣

2 Likes

Good one @ambarlamedya :rofl:

1 Like

I will definitely use this in my latest projects.

1 Like