update links text based on related HTML snippet