function to extract wid from url added