docs: public String getProjectSelect(String htmlAttributes, String htmlWidth) {
  
          // get all project information
          List<CmsProject> allProjects;
          try {
              String ouFqn = "";
              CmsUserSettings settings = new CmsUserSettings(getCms());
              if (!settings.getListAllProjects()) {
                  ouFqn = getCms().getRequestContext().getCurrentUser().getOuFqn();
              }
              allProjects = OpenCms.getOrgUnitManager().getAllAccessibleProjects(
                  getCms(),
                  ouFqn,
                  settings.getListAllProjects());
          } catch (CmsException e) {
              // should usually never happen
              if (LOG.isErrorEnabled()) {
                  LOG.error(e.getLocalizedMessage(), e);
              }
              allProjects = Collections.emptyList();
          }
          allProjects = filterProjectsForSelector(allProjects);
  
          boolean singleOu = true;
          String ouFqn = null;
          Iterator<CmsProject> itProjects = allProjects.iterator();
          while (itProjects.hasNext()) {
              CmsProject prj = itProjects.next();
              if (prj.isOnlineProject()) {
                  // skip the online project
                  continue;
              }
              if (ouFqn == null) {
                  // set the first ou
                  ouFqn = prj.getOuFqn();
              }
              if (!ouFqn.equals(prj.getOuFqn())) {
                  // break if one different ou is found
                  singleOu = false;
                  break;
              }
          }
  
          List<String> options = new ArrayList<String>();
          List<String> values = new ArrayList<String>();
          int selectedIndex = -1;
          int ouDefaultProjIndex = -1;
  
          CmsOrganizationalUnit ou = null;
          try {
              ou = OpenCms.getOrgUnitManager().readOrganizationalUnit(getCms(), getCms().getRequestContext().getOuFqn());
          } catch (CmsException e) {
              // should never happen, ignore
          }
  
          // now loop through all projects and fill the result vectors
          for (int i = 0, n = allProjects.size(); i < n; i++) {
              CmsProject project = allProjects.get(i);
              String projectId = project.getUuid().toString();
              String projectName = project.getSimpleName();
              if (!singleOu && !project.isOnlineProject()) {
                  try {
                      projectName = projectName
                          + " - "
                          + OpenCms.getOrgUnitManager().readOrganizationalUnit(
                              getCms(),
                              project.getOuFqn()).getDisplayName(getLocale());
                  } catch (CmsException e) {
                      projectName = projectName + " - " + project.getOuFqn();
                  }
              }
  
              values.add(projectId);
              options.add(projectName);
  
              if (project.getUuid().equals(getSettings().getProject())) {
                  // this is the user's current project
                  selectedIndex = i;
              }
              if ((ou != null) && project.getUuid().equals(ou.getProjectId())) {
                  ouDefaultProjIndex = i;
              }
          }
          if (selectedIndex == -1) {
              if (ouDefaultProjIndex == -1) {
                  selectedIndex = 0;
              } else {
                  selectedIndex = ouDefaultProjIndex;
              }
          }
          if (CmsStringUtil.isNotEmpty(htmlWidth)) {
              StringBuffer buf = new StringBuffer(htmlAttributes.length() + htmlWidth.length() + 2);
              buf.append(htmlAttributes);
              buf.append(" ");
              buf.append(htmlWidth);
              htmlAttributes = buf.toString();
          }
  
          return buildSelect(htmlAttributes, options, values, selectedIndex);
      }