Switch to the offline project
From OpenCms Wiki
(Difference between revisions)
m |
|||
Line 1: | Line 1: | ||
− | + | <source lang="java"> | |
− | + | ... | |
− | + | // setting current project to 'Offline' | |
− | + | CmsRequestContext cmsContext = cmsObject.getRequestContext(); | |
+ | CmsProject offlineProject = cmsObject.readProject("Offline"); | ||
+ | cmsContext.setCurrentProject(offlineProject); | ||
+ | ... | ||
+ | </source> |
Latest revision as of 14:44, 5 January 2012
... // setting current project to 'Offline' CmsRequestContext cmsContext = cmsObject.getRequestContext(); CmsProject offlineProject = cmsObject.readProject("Offline"); cmsContext.setCurrentProject(offlineProject); ...