Solved

Workflow regular expression: replace url part after 3rd slash

  • 21 February 2022
  • 1 reply
  • 18 views

Badge +1

I've got a regular expression action in Nintex Workflow where I need to replace everything after the third slash of a url.



- This is the url: http://www.testurl.com/this-part/needs-to/be-replaced



- This part should be replaced: this-part/needs-to/be-replaced



- With this: become-this




So the final url is like this: http://www.testurl.com/become-this 



 



What Regex pattern should I use for this?

icon

Best answer by mlauer 21 February 2022, 10:37

View original

1 reply

You can use the pattern ^([^/]+//[^/]+/).*$ and the replacement text $1become-this



 



 



Reply