changed tab clear to find elements rather than looping through static list