Determine whether to jQuery search by class or ID name