added tab functionality