<html>
<body text="#000000" bgcolor="#ffffff">
<p>Diese Dave<br>
<br>
As far as I understand it you are right that the export names for the two
sites must be different. This means that you have to export the sites into
different subfolders. These subfolders will then also be needed on the
weebserver itself - at least if you use absolute paths. So site 2 would
live in a folder called "2" and you would have to put an
alternative index file onto the server that redirects from /index.html to
/2/index.html<br>
Probably you also have to export site 1 into a subfolder to make sure that
the two experts don't get mixed up.<br>
<br>
This kind of setup definitely works.<br>
<br>
In addition you can try to configure opencms to use relative links and see
if that allows you to put the second site into the httproot folder despite
exporting it into a subfolder. Last time I tried relative links I went into
some sort of trouble but this was several years ago. Sadly I don't
recall what exactly the trouble was.<br>
<br>
This is all that I can think of.<br>
<br>
Good look<br>
Christian<br>
<br>
<br>
Gesendet mit AquaMail für Android<br>
<a href="http://www.aqua-mail.com">http://www.aqua-mail.com</a></p>
<br><p>
<p>Am 27. April 2013 00:53:50 schrieb Dave Clark <daveclark@utah.gov>:</p>
<blockquote type="cite">
<div dir="ltr"><div
style="font-family:arial,sans-serif;font-size:12.800000190734863px"><br
class="">Is it possible to use opencms as a content management system for
multiple completely static sites? We are running v8.5.1 in Tomcat7 as the
root context. All content from multiple sites is static and should be
exported (i.e., not ever served directly from opencms except by the 404
handler when appropriate). There is a web server in front of tomcat that
maps root directories to /path/to/site1 and /path/to/site2 respectively and
forwards 404 errors to the opencms handler. However, even if I call the
404 handler directly using <a
href="http://site1:8080/opencms/handle404?exporturi=/index.html"
target="_blank">http://site1:8080/opencms/handle404?exporturi=/index.html</a> or <a
href="http://site2:8081/opencms/handle404?exporturi=/sites/2/index.html"
target="_blank">http://site2:8081/opencms/handle404?exporturi=/sites/2/index.html</a>,
the files in site2 always get written as /path/to/site2/sites/2/[filename]
and the links inside that file include the /sites/2/[filename] in the href
which makes the url <a href="http://site2:8081/sites/2/%5Bfilename%5D"
target="_blank">http://site2:8081/sites/2/[filename]</a><br>
</div><div
style="font-family:arial,sans-serif;font-size:12.800000190734863px"><br></div><div
style="font-family:arial,sans-serif;font-size:12.800000190734863px">The
site1 files seem to behave correctly. Is there a configuration element that
isn't being set that could be causing this? The two folders
(/sites/default and /sites/2) cannot have the same exportname property
"/" so I can't see how this would ever work. The document
at <a
href="http://www.algoa.ch/opencms/export/sites/default/alkacon-documentation/documentation_staticexport/advanced/tutorial.html"
target="_blank">http://www.algoa.ch/opencms/export/sites/default/alkacon-documentation/documentation_staticexport/advanced/tutorial.html</a> seems
to indicate this is possible but I just can't make it work. </div>
<div
style="font-family:arial,sans-serif;font-size:12.800000190734863px"><br></div><div
style="font-family:arial,sans-serif;font-size:12.800000190734863px">Below
is a snippet of opencms-importexport.xml:</div><div
style="font-family:arial,sans-serif;font-size:12.800000190734863px">
<br></div><div
style="font-family:arial,sans-serif;font-size:12.800000190734863px"><div>
<staticexport enabled="true"></div><div>
<staticexporthandler>org.opencms.staticexport.CmsOnDemandStaticExportHandler</staticexporthandler></div>
<div>
<linksubstitutionhandler>org.opencms.staticexport.CmsDefaultLinkSubstitutionHandler</linksubstitutionhandler></div><div>
<exportpath>/path/to/site1</exportpath></div><div>
<exportworkpath>temp</exportworkpath></div>
<div> <exportbackups>2</exportbackups></div><div>
<defaultpropertyvalue>true</defaultpropertyvalue></div><div>
<defaultsuffixes></div><div> <suffix
key=".jpg"/></div>
<div> <suffix key=".gif"/></div><div> <suffix
key=".png"/></div><div> <suffix
key=".doc"/></div><div> <suffix
key=".xls"/></div><div> <suffix
key=".ppt"/></div>
<div> <suffix key=".pdf"/></div><div> <suffix
key=".txt"/></div><div> <suffix
key=".css"/></div><div> <suffix
key=".zip"/></div><div> <suffix
key=".swf"/></div>
<div> </defaultsuffixes></div><div>
<rendersettings></div><div>
<rfs-prefix></rfs-prefix></div><div>
<vfs-prefix>${SERVLET_NAME}</vfs-prefix></div><div>
<vfs-prefix>${SERVLET_NAME}</vfs-prefix>--></div>
<div>
<userelativelinks>true</userelativelinks></div><div>
<exporturl>http://site1:8080${SERVLET_NAME}/handle404</exporturl></div><div>
<plainoptimization>true</plainoptimization></div>
<div> <testresource
uri="/system/shared/page.dtd"/></div><div>
<resourcestorender></div><div>
<regex>/sites/.*</regex></div><div>
<regex>/system/workplace/commons/style/.*</regex></div>
<div> <regex>/system/galleries/.*</regex></div><div>
<regex>/system/modules/.*/resources/.*</regex></div><div>
</resourcestorender></div><div> <rfs-rules></div>
<div>
<rfs-rule></div><div>
<name>site2</name></div><div> <description>site2
rfs location</description></div><div>
<source>/sites/2/.*</source></div>
<div>
<rfs-prefix></rfs-prefix></div><div>
<exportpath>/path/to/site2</exportpath></div><div>
<userelativelinks>false</userelativelinks></div><div>
<related-system-res/></div>
<div> </rfs-rule></div><div>
</rfs-rules></div><div> </rendersettings></div><div>
</staticexport></div><div><br></div><div>I have also changed the
above so that /sites/default (site1) has its own rfs-rule but the result is
the same. Here is the site config from opencms-system.xml:</div>
<div><br></div><div><div> <sites></div><div>
<workplace-server><a href="http://site1:8080/"
target="_blank">http://site1:8080</a></workplace-server></div><div>
<default-uri>/sites/default/</default-uri></div>
<div> <site server="<a href="http://site1:8080/"
target="_blank">http://site1:8080</a>"
uri="/sites/default/"/></div><div> <site
server="<a href="http://site2:8081/"
target="_blank">http://site2:8081</a>"
uri="/sites/hmis/"/></div>
<div> </sites></div></div></div><div><br></div>--
<br><div>Dave Clark<br><br></div>
</div>
</blockquote>
</body>
</html>