 ----------------------------------------------------------------------------------------------
   PROCEDURE writeFolder(pProjectID IN NUMBER, pResource IN cms_resources%ROWTYPE, pChange IN VARCHAR2) IS
     vState NUMBER;
-    vOnlineProject NUMBER;
+    vOnlineProject NUMBER := opencmsconstants.C_PROJECT_ONLINE_ID;
     vTableName VARCHAR2(20);
   BEGIN
-    vOnlineProject := opencmsProject.onlineProject(pProjectID).project_id;
     IF pProjectID = vOnlineProject THEN
       vTableName := 'CMS_ONLINE_RESOURCES';
     ELSE

    END IF;
  EXCEPTION
    WHEN OTHERS THEN
      IF curOnlineProject%ISOPEN THEN
        CLOSE curOnlineProject;
      END IF;
      IF curFileHeader%ISOPEN THEN
        CLOSE curFileHeader;
      END IF;

    curSubResource userTypes.anyCursor;
    recSubResource cms_resources%ROWTYPE;
    tableResource userTypes.resourceTable;
    vOnlineProject NUMBER := opencmsconstants.C_PROJECT_ONLINE_ID;
    vTableName VARCHAR2(20);
  BEGIN
    IF pProjectId = vOnlineProject THEN
      vTableName := 'CMS_ONLINE_RESOURCES';
    ELSE
