Hello, I am trying to extract domain from URL with regex in variable and in second variable whole URL: www.google.com | https://www.google.com/search?sxsrf=ACY... This is what i figured out. Could you explain to me how i can use second variable in the same array? Because when i try to use it like this: The result is completely empty. When i using it in this way: The result is: www.google.com none ... I was trying to make second group with regex. In first group to get only domain, in second group to get whole URL but working the same as above (*domain* none) Thanks!
Do as in the screenshot below: use two groups in the regular expression and output the result correctly.
Okay, so the problem was in my regex pattern. $1,$2,$3,... in arrays mean groups from regex pattern, am i right?