I saw some posts like this, but not quite what I want to do.
How to extract and remove URL links and then remove them from plain text.
Example:
"Hello!!, I love http://www.google.es".
I want to extract "http://www.google.es", save it to a variable, and then remove it from my text.
Finally, the text should be like this:
"Hello!!, I love".
URLs are usually the last "word" of text, but not always.
source
share