[opencms-dev] xmlContent, load expired files

Markus Daniel markus.daniel at synyx.de
Sat Oct 8 17:01:59 CEST 2005


Hello!

I have a list (htmlPage with links to singleFiles) with all expired 
files in one folder generated with the contentloadTag and an own collector:

<cms:contentload collector="allInFolderDateDescAll" 
param="/sites/default/expiredFiles/" editable="true">

Now I want to display the content of such a file,
I tried this with following code
<cms:contentload collector="singleFileAll" param="${opencms.uri}" 
editable="true">
but I always get the following exception

org.opencms.file.CmsVfsResourceNotFoundException: Error reading resource 
from path "/sites/default/expiredFiles/singleFile".
     at 
org.opencms.file.CmsVfsResourceNotFoundException.createException(CmsVfsResourceNotFoundException.java:75)
     at org.opencms.db.CmsDbContext.throwException(CmsDbContext.java:213)
     at org.opencms.db.CmsDbContext.report(CmsDbContext.java:197)
     at 
org.opencms.db.CmsSecurityManager.readResource(CmsSecurityManager.java:3743)
     at org.opencms.file.CmsObject.readResource(CmsObject.java:2587)
     at org.opencms.file.CmsObject.readResource(CmsObject.java:2553)
     at org.opencms.main.OpenCmsCore.initResource(OpenCmsCore.java:1140)
     at org.opencms.main.OpenCmsCore.showResource(OpenCmsCore.java:1299)
     at org.opencms.main.OpenCmsServlet.doGet(OpenCmsServlet.java:136)

So I looked into the initResource-Methode of OpenCmsCore and changed
	resource = cms.readResource(resourceName);
to
         resource = cms.readResource(resourceName, CmsResourceFilter.ALL);

Now my question, is this a bug or is there any other possibility to load 
expired resources?

Thanks.

Regards,
Markus



More information about the opencms-dev mailing list