This seems like really really brittle code that will break if we change anything in the UI layout? Wouldn't a form of named search be better?