0

I want to take my 'item.title' string and store a match from a regular expression into 'item.myRegexMatch'. However, it's unclear to me how to achieve this, as all the Regex modules in YP require a "replacement" string. I don't want to replace anything; I just want the Regex match returned. This seems trivial, but I'm fairly new with YP and regular expressions, so hopefully I'm simply overlooking this basic functionality.

1 Answer 1

1

Quick answer :

Steps :

1/ Rename module :

[item.title] COPY [item.myRegexMatch] 

2/ Regex module :

in [item.myRegexMatch] replace [^.*(YOURREGEX).*] with [$1] ^ ^ 

be sure to keep the 2 parentheses indicated in the above line.

Explaination :

The parentheses in the "replace" field define a backreference.

This backrefencere is then used ($1) in the "with" field.

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.