code: public void setWorkplaceSite(String newSite) {
  
          String oldSite = getWorkplaceSite();
          // get the site list
          String siteList = getExtProperty("site.root.list");
          // replace old site URL in site list with new site URL
          siteList = CmsStringUtil.substitute(siteList, oldSite, newSite);
          setExtProperty("site.root.list", siteList);
          setExtProperty("site.workplace", newSite);
      }
docs: Sets the OpenCms workplace site.<p>
  
  @param newSite the OpenCms workplace site