Horje
python regex for a url Code Example
python regex for a url
import re

url = '<p>Hello World</p><a rel="nofollow" href="http://example.com">More Examples</a><a rel="nofollow" href="http://example2.com">Even More Examples</a>'

urls = re.findall('https?://(?:[-\w.]|(?:%[\da-fA-F]{2}))+', url)

>>> print urls
['http://example.com', 'http://example2.com']




Python

Related
df sort values Code Example df sort values Code Example
print current dirfile dir python Code Example print current dirfile dir python Code Example
get list of unique values in pandas column Code Example get list of unique values in pandas column Code Example
convert column to datetime format python Code Example convert column to datetime format python Code Example
get directory of file python Code Example get directory of file python Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
6