RegExp - can't find out how to use in practice

Hello there. Could you please clarify for me how to create RegExp for the text below:
I need to save only website pages

let  fullList = 
`
https://somewebsite.com/blog/	0	2013-03-23 13:20 -04:00
https://somewebsite.com/2012/12/29/premium-wordpress-themes/	0	2012-12-29 12:59 -05:00
https://somewebsite.com/2012/12/30/mauris-pharetra-interdum/	0	2012-12-30 13:06 -05:100
` ;

let regExp = /???/;
let result = text.match(regExp);

What I expect:

https://somewebsite.com/blog/
https://somewebsite.com/2012/12/29/premium-wordpress-themes/
https://somewebsite.com/2012/12/30/mauris-pharetra-interdum/

I suppose I should cut all words which start with ‘https’ and end with first space? How to write this?

Something like this: https://jsfiddle.net/anw543q7/ ?

1 Like

this code may help you.

var regex=/(^([(https:)]+)([//])([a-z./-\d])*( \s|[/]))/gm

let fullList =

`

https://somewebsite.com/blog/ 0 2013-03-23 13:20 -04:00

https://somewebsite.com/2012/12/29/premium-wordpress-themes/ 0 2012-12-29 12:59 -05:00

https://somewebsite.com/2012/12/30/mauris-pharetra-interdum/ 0 2012-12-30 13:06 -05:100

`

var result=fullList.match(regex)

console.log(result)

1 Like

Thank you guys. Much appreciated. :slight_smile: