I have written a regex query to extract a URL. Sample text:
<p>a tinyurl here <a href="https://vvvconf.instenv.atl-test.space/x/HQAU">https://vvvconf.instenv.atl-test.space/x/HQAU</a></p>
URL I need to extract:
https://vvvconf.instenv.atl-test.space/x/HQAU
My regex attempts:
-
https:\/\/vvvconf.[a-z].*\/x\/[a-zA-z0-9]*
This extracts:
{"https://vvvconf.instenv.atl-test.space/x/HQAU">https://vvvconf.instenv.atl-test.space/x/HQAU"}
-
>https:\/\/vvvconf.[a-z].*\/x\/[a-zA-z0-9]*<
This extracts:
{">https://vvvconf.instenv.atl-test.space/x/HQAU<"}
How can I refine the regex so I just extract the URL https://vvvconf.instenv.atl-test.space/x/HQAU
?