Newbie: Suggestions for development environment
I am a technical writer learning to use Cocoon. I have read the FAQs and done Google searches for an answer to this question (which doesn't mean that it is not out there somewhere, of course). I have installed Cocoon and experimented with it somewhat successfully and would like to begin building and deploying a webapp that will create dynamic documentation. I am creating my project on a Linux box on a home network, and will deploy to a Web server on the Internet. I would like to keep the full Cocoon installation (2.0.3 on Tomcat 4.1.18) on my home box, but don't particularly want to burden my hosting provider with all of the samples, documentation, and other overhead of the full install. I am confused after reading about setting up a development environment and deploying webapps. I have created multiple Cocoon instances, but am not sure this is the best way to do it. The reason I say this, is that when I access localhost/cocoon I see the directory page; but when I access localhost/cocoon_dev (the second instance, set up with intentions of creating a Cocoon instance with minimal overhead for my webapp) I get a 404 error. This tells me that something is amiss (I think). Another method I have read says that the way to do it is to create a webapp directory within the cocoon/mount directory and use a subsitemap. OK. But when I deploy from my local (home network) machine to my provider's machine (on the Internet) I will have to create a new sitemap that references whatever components the webapp requires. Maybe this is no big deal to experienced Cocoon developers/users but it seems like an opportunity for a lot of confusion and extra work. What is the best practice for this that allows the most hassle-free deployment with the least opportunity for breaking the webapp in moving it from local machine to host machine? You may reply off-list if you like and I will post whatever works for other newbies. As always, let me know if I have left out information that would be helpful in understanding the question, and I will provide it. Or, if there is a link that explains this, that would be fine, as well. Thanks. Joe
Re: Content formats
Studying the DocBook DTD and XSLs can be instructional, as well, for rolling your own. DITA seems to be developed specifically to move away from the book paradigm for creating information products. You can read about it and download the DTDs and XSLs from IBM. Info at the links. Joe http://www-106.ibm.com/developerworks/xml/library/x-dita1/#h1 http://www-106.ibm.com/developerworks/xml/library/x-dita2/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat problem (newbie)
After changing a parameter in my main sitemap, and then restoring the original config, my Tomcat will not start. Looking at the catalina.out log, I find the error pasted below. Clues, please? java.lang.NoClassDefFoundError at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:115) at org.apache.jk.server.JkMain.newHandler(JkMain.java:556) at org.apache.jk.server.JkMain.processProperty(JkMain.java:537) at org.apache.jk.server.JkMain.processProperties(JkMain.java:505) at org.apache.jk.server.JkMain.start(JkMain.java:346) at org.apache.jk.server.JkCoyoteHandler.start(JkCoyoteHandler.java:169) at org.apache.coyote.tomcat4.CoyoteConnector.start(CoyoteConnector.java:1056) at org.apache.catalina.core.StandardService.start(StandardService.java:506) at org.apache.catalina.core.StandardServer.start(StandardServer.java:2189) at org.apache.catalina.startup.Catalina.start(Catalina.java:512) at org.apache.catalina.startup.Catalina.execute(Catalina.java:400) at org.apache.catalina.startup.Catalina.process(Catalina.java:180) at java.lang.reflect.Method.invoke(Native Method) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203) [ERROR] JkMain - -Can't create channelSocket java.lang.NoClassDefFoundError - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat problem (newbie)
Sorry for the waste of bandwidth, but you can disregard the previous message. Joe - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie question about CSS display
Forgive the elementary nature of this question, but I am new to Cocoon, my background is documentation and not development, and I have read and searched for an explanation for this weirdness without success. Using DocBook XML and the DocBook XSL with a customization layer, I want to change the styles using a CSS. My formatting changes are displayed when I run the transformation from the command line, but not when I use Cocoon. Is this to be expected, or what? Does the transformation occur differently when using Cocoon than when using Xalan alone? A helpful link or answer would be appreciated. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question about CSS display
The link to the stylesheet appears in the HTML output. I am using a sub-sitemap with the pipeline: map:pipeline map:match pattern=book map:generate src=book.xml/ map:transform src=book.xsl map:parameter name=css-stylesheet value=book.css/ /map:transform map:serialize/ /map:match map:match pattern=*.css map:read src={1}.css mime-type=text/css/ /map:match /map:pipeline And I am adding the parameters to my DocBook customization layer, per Norm and Bob's documentation: xsl:param name=html.stylesheet select='book.css'/ xsl:param name=html.stylesheet.typetext/css/xsl:param - Original Message - From: Yves Vindevogel [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, March 28, 2003 9:27 AM Subject: Re: Newbie question about CSS display Check your sitemap ... You probably don't have the correct pipeline/match for it. Forgive the elementary nature of this question, but I am new to Cocoon, my background is documentation and not development, and I have read and searched for an explanation for this weirdness without success. Using DocBook XML and the DocBook XSL with a customization layer, I want to change the styles using a CSS. My formatting changes are displayed when I run the transformation from the command line, but not when I use Cocoon. Is this to be expected, or what? Does the transformation occur differently when using Cocoon than when using Xalan alone? A helpful link or answer would be appreciated. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Met vriendelijke groeten, Kind regards, Bien à vous, Yves Vindevogel Implements Kempische Steenweg 206 -- 3500 Hasselt -- Belgium Phone/Fax: +32 (11) 43.55.76 -- Mobile: +32 (478) 80.82.91 Mail: [EMAIL PROTECTED] -- www.implements.be Quote: The winner never says participating is more important than winning. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question about CSS display
When I try to reach the CSS directly, I get a Cocoon error (see below). What do you want to reach with map:parameter name=css-stylesheet value=book.css/ ?? Do you have a global xsl:param name=css-stylesheet/ in your book.xsl? No, I do not. I commented that line out, and the link to the CSS still appears in the HTML result, so it obviously doesn't do anything useful here. Not sure why I put that in there, except for my newbieness...just hacking around to see if I could get it to work. This only for clarification. Test the stylesheet independent of the DocBook HTML with http://myserver:8080/cocoon/book/book.css;. If you get it, hmm, I don't know. If not, what do you get? When I follow the suggestion to access the CSS alone, I get this error: type resource-not-found message Resource not found description The requested URI /cocoon/book/book.css was not found. sender org.apache.cocoon.servlet.CocoonServlet source Cocoon servlet request-uri /cocoon/book/book.css path-info book/book.css - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question about CSS display
1. the file is not in the same directory as the xml (according to the earlier sent match patterns and pipelines), 2. the pipeline for the CSS does not look like the sent one 3. or there is another pipeline matching on *.css before the sent one. And this one searches for the CSS file on another place on the disk. A look into the log file, especially for stacktraces, will help I think. Maybe one can see a FileNotFoundException (or Resource...) with the specified path, where the file was searched for. In access.log: WARN (2003--3-28) 16:41.55.945 [access] (/cocoon/book/book.css) Thread-7/CocoonServlet: The resource was not found org.apache.cocoon.ResourceNotFoundException: No pipeline matched request: book/book.css In sitemap.log: DEBUG (2003-03-28) 16:41:55.909 [sitemap] (/cocoon/book/book.css) Thread-7/sitemap_xmap: Matched wildcard pattern book/* DEBUG (2003-03-28) 16:41:55.909 [sitemap] (/cocoon/book/book.css) Thread-7/AbstractSitemap: Current Sitemap Parameters: PARAM: VALUE: 'book.css' PARAM: '0' VALUE: 'book'/book.css' - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question about CSS display
Ah, interesting ;-) As I expected it ... Please have a look into the log files. You should get more information there, e.g. something like a stacktrace. It seems, that the book.css can't be found on the disk, where it should be to found (as you specified it in the sitemap). But the pipeline matching on *.css you sent already in this thread looked ok. Maybe another pipeline matches already earlier on *.css in the sitemap? There is a *.css in the main sitemap. Would that conflict with this one in this sub-sitemap (cocoon/book/sitemap.xmap)? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question about CSS display--CORRECTION
There is no *.css in main sitemap, but I have not looked through all the files. - Original Message - From: Joe Williams [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, March 28, 2003 4:52 PM Subject: Re: Newbie question about CSS display Ah, interesting ;-) As I expected it ... Please have a look into the log files. You should get more information there, e.g. something like a stacktrace. It seems, that the book.css can't be found on the disk, where it should be to found (as you specified it in the sitemap). But the pipeline matching on *.css you sent already in this thread looked ok. Maybe another pipeline matches already earlier on *.css in the sitemap? There is a *.css in the main sitemap. Would that conflict with this one in this sub-sitemap (cocoon/book/sitemap.xmap)? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie question about CSS display
Thanks for the response, let me see if this makes things clearer. I'm not getting an error message, but the formatting changes to the DocBook XSL (by means of my CSS) do not appear in the browser. The URL: http://myserver:8080/cocoon/book/book This succeeds in calling the document. When I view the source of the displayed HTML, the link to the CSS stylesheet appears: link href=book.css rel=stylesheet type=text/css Therefore, I expect the changes to appear, but they do not. The CSS is in the same directory (book) as the XML source (book.xml) the XSL stylesheet (book.xsl) and the CSS (book.css) I have not tried Lionel's suggestions yet, but will do so. - Original Message - From: Joerg Heinicke [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, March 28, 2003 10:19 AM Subject: Re: Newbie question about CSS display Hello Joe, you don't give very exact error description, only it does not work. So it's only possible to guess. Or you give us more information. I guess the error is a missing or a wrong match for the CSS. The information you can provide: 1. Which URL do you type in the browser for the Cocoon delivered HTML. 2. How does the according match pattern in the sitemap for the docbook transformation look like. 3. How does the link/ tag for the CSS in the generated HTML look like? 4. How does the according match pattern in the sitemap for the CSS look like? The transformation offline or in Cocoon may be different (but I don't really think so), but has nothing to do with the loading of the CSS. Regards, Joerg Joe Williams wrote: Forgive the elementary nature of this question, but I am new to Cocoon, my background is documentation and not development, and I have read and searched for an explanation for this weirdness without success. Using DocBook XML and the DocBook XSL with a customization layer, I want to change the styles using a CSS. My formatting changes are displayed when I run the transformation from the command line, but not when I use Cocoon. Is this to be expected, or what? Does the transformation occur differently when using Cocoon than when using Xalan alone? A helpful link or answer would be appreciated. -- System Development VIRBUS AG Fon +49(0)341-979-7419 Fax +49(0)341-979-7409 [EMAIL PROTECTED] www.virbus.de - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Newbie: DocBook XSL success
Thanks, Joerg. I replaced the old xalan with Xalan-J 2.4.1 and the transformation works, except for a problem with CSS. For subsequent newbies looking for a setup that works, here's what I am using. Cocoon 2.0.3 with jre 1.3.1_06 DocBook XML DTD 4.2 DocBook XSL 1.5 The following .jar files are in the cocoon/WEB-INF/lib xalan-2.4.1.jar xalan2.jar (docbook extensions from Norm) xercesImpl-2.0.0.jar xml-apis.jar - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Docbook+CSS: Styles not displayed
The doc displays, and the link to the CSS is present in the HTML for the result document, but for some reason it does not display when requested from Cocoon. It does display when I run the transform from the command line. I am using a sub-sitemap with the pipeline: map:pipeline map:match pattern=book map:generate src=book.xml/ map:transform src=book.xsl map:parameter name=css-stylesheet value=book.css/ /map:transform map:serialize/ /map:match map:match pattern=*.css map:read src={1}.css mime-type=text/css/ /map:match /map:pipeline And I am adding the parameters to my DocBook customization layer, per Norm and Bob's documentation: xsl:param name=html.stylesheet select='book.css'/ xsl:param name=html.stylesheet.typetext/css/xsl:param - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Newbie: Best practices for DocBook XSL on Cocoon
I have a question about using DocBook XSL with Cocoon, for anyone who has been successful in doing so. In hopes of getting some help and maybe helping others, I offer the following background. After reading numerous posts to the archives for this list, and other resources, I am aware that not everyone is in favor of using the DocBook XSL stylesheets with Cocoon. However, I have also found that some people have done so successfully, and would like to do so myself. I have been successful in serving DocBook XML content with a homegrown XSL stylesheet and CSS, but when I attempted to use the DocBook XSL to produce html, I get a blank page. (The transform runs fine from the command line.) Looking at cocoon/WEB-INF/logs/error.log I see a fatal exception in "docbook/html/common/common.xsl; Line 1576; Column 35", "javax.xml.transform.TransformerException: 13 = 1" and farther down in the log, I see"java.lang.ArrayIndexOutOfBoundsException: 13 = 1" Going to "docbook/html/common/common.xsl; Line 1576; Column 35", I see the following: xsl:when test="$value !="''" OK, so xalan doesn't like this line, I guess? Here's my setup: Cocoon 2.0.3 Using these classes in /usr/tomcat/webapps/cocoon/WEB-INF/lib: xalan-2.3.1.jar xalan2.jar (docbook extensions from Norm) xercesImpl-2.0.0.jar xml-apis.jar Using jre 1.3.1_06 DocBook XML DTD 4.2 DocBook XSL 1.5 I would like to keep using xalan, but if I have to add saxon, please point me to a good procedure for doing so. Ditto for any other suggestions. When I get the setup working, I will post the info to the list. Thanks. Joe