[Yanel-commits] rev 20671 -
public/yanel/trunk/src/contributions/resources/wiki/src/java/org/wyona/yanel/impl/resources
michi at wyona.com
michi at wyona.com
Fri Dec 8 09:35:29 CET 2006
Author: michi
Date: 2006-12-08 09:35:28 +0100 (Fri, 08 Dec 2006)
New Revision: 20671
Modified:
public/yanel/trunk/src/contributions/resources/wiki/src/java/org/wyona/yanel/impl/resources/WikiResource.java
Log:
hardcoded XSLT removed during creation and bug re root started to fix
Modified: public/yanel/trunk/src/contributions/resources/wiki/src/java/org/wyona/yanel/impl/resources/WikiResource.java
===================================================================
--- public/yanel/trunk/src/contributions/resources/wiki/src/java/org/wyona/yanel/impl/resources/WikiResource.java 2006-12-08 08:34:25 UTC (rev 20670)
+++ public/yanel/trunk/src/contributions/resources/wiki/src/java/org/wyona/yanel/impl/resources/WikiResource.java 2006-12-08 08:35:28 UTC (rev 20671)
@@ -362,13 +362,21 @@
RepoPath rpRTI = new org.wyona.yarep.util.YarepUtil().getRepositoryPath(new org.wyona.yarep.core.Path(path.toString()), yanel.getRepositoryFactory("RTIRepositoryFactory"));
repository = rpRTI.getRepo();
- org.wyona.yarep.core.Path newPath = new org.wyona.yarep.core.Path(rpRTI.getPath().getParent() + "/" + createName);
+ org.wyona.yarep.core.Path newPath = null;
+ if (rpRTI.getPath().getParent().equals("null")) {
+ newPath = new org.wyona.yarep.core.Path("/" + createName);
+ } else {
+ newPath = new org.wyona.yarep.core.Path(rpRTI.getPath().getParent() + "/" + createName);
+ }
+ String content = "<{http://www.wyona.org/yanel/resource/1.0}wiki/>";
+
// TODO: Do not hardcode xslt ...
- String content = "<{http://www.wyona.org/yanel/resource/1.0}wiki/>\nxslt: /xslt/global.xsl";
- // TODO: Make mime-type configurable
- //String content = "<{http://www.wyona.org/yanel/resource/1.0}wiki/>\nmime-type: application/xhtml+xml\nxslt: /xslt/global.xsl";
+ //content = content + "\nxslt: /xslt/global.xsl";
+ // TODO: Make mime-type configurable (depending on global XSLT) ...
+ content = content + "\nmime-type: application/xhtml+xml";
+
log.info("Writing content to repository " + repository.getName() + " with content:\n" + content + "\nto path: " + newPath);
Writer writer = repository.getWriter(new org.wyona.yarep.core.Path(new Path(newPath.toString()).getRTIPath().toString()));
More information about the Yanel-commits
mailing list