working extraction of links