added onsite/offsite switch