Common functions set up in one selector.