Sergiu, Thanks a lot for your quick reply and help. May I ask one more question, related to errors displayed on the Tomcat console?
Any idea why I am getting the following exception (http://www.airl ine-tickets.dl.pl is not something I have entered anywhere ...)? Thanks in advance. Darina 20:12:08,241 [http://iiscs.wssu.edu/xwiki/bin/viewrev/Photos/URL=http://www.airl ine-tickets.dl.pl] [http-80-Processor8] ERROR log.SimpleLog4JLogSystem - Method display threw exception for reference $doc in template at [12,7] org.apache.velocity.exception.MethodInvocationException: Invocation of method 'display' in class com.xpn.xwiki.api.Document threw exception java.lang.NullPoint erException @ <unknown template>[12,13] at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.j ava:286) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTRefer ence.java:203) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTRefere nce.java:294) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java :74) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode. java:318) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfSt atement.java:107) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java :74) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfSt atement.java:88) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode. java:318) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(Velocim acroProxy.java:194) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirect ive.java:170) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java :74) at org.apache.velocity.runtime.directive.Foreach.render(Foreach.java:448 ) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirect ive.java:170) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java :74) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfSt atement.java:88) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode. java:318) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRend erer.java:238) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRend erer.java:152) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1366) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1335) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:607) at sun.reflect.GeneratedMethodAccessor162.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.in voke(UberspectImpl.java:295) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.j ava:245) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTRefer ence.java:203) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTRefere nce.java:294) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode. java:318) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(Velocim acroProxy.java:194) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirect ive.java:170) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode. java:318) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRend erer.java:238) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRend erer.java:152) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1366) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1335) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:607) at sun.reflect.GeneratedMethodAccessor162.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.in voke(UberspectImpl.java:295) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.j ava:245) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTRefer ence.java:203) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTRefere nce.java:294) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode. java:318) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(Velocim acroProxy.java:194) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirect ive.java:170) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode. java:318) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRend erer.java:238) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRend erer.java:152) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1366) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1335) at com.xpn.xwiki.web.Utils.parseTemplate(Utils.java:105) at com.xpn.xwiki.web.Utils.parseTemplate(Utils.java:48) at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:186) at org.apache.struts.action.RequestProcessor.processActionPerform(Reques tProcessor.java:431) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.ja va:236) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:119 6) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl icationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF ilterChain.java:173) at com.xpn.xwiki.web.SetCharacterEncodingFilter.doFilter(SetCharacterEnc odingFilter.java:117) -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sergiu Dumitriu Sent: Thursday, February 07, 2008 8:27 PM To: XWiki Users Subject: Re: [xwiki-users] Error on Tomcat console possibly related to adding a second blog Dicheva, Darina wrote: > Hello, > > I have installed xwiki 1.2 (MySql, Tomcat 5), and created a second blog > following a suggestion in a previous postage to this list (by adding the > $space variable to the blog macro). Everything seems to work just fine, > but nevertheless I get error messages displayed on the Tomcat console, > such as: > > 16:40:41,008 [http://iiscs.wssu.edu/xwiki/bin/view/Blog/] > [http-80-Processor4] ERROR log.SimpleLog4JLogSystem - Left side > ($bentrydoc.fullName) of '==' operation has null value. If a reference, > it may not be in the context. Operation not possible. Blog.WebHome [line > 20, column 28] > > It seems that the error is in the Blog.Macros' line below (I edited the > original line to include $space): > > #if(($bentrydoc.fullName == $item)&& (!$space ||($space=="") || > ($bentrydoc.getSpace()==$space)) ) > > Is it normal to get those kind of messages, and if not, is this a result > of my modification, and how can I fix it? > > Since I don't really know Velocity, any advice will be highly > appreciated. > > Thanks, > Darina > Hi, The error is not cause by adding $space in there. I think this is an error in the original script, but it is not a severe one. You can fix it if you replace the line with: #if($bentrydoc && ($bentrydoc.fullName == $item) && (!$space || ($space=="") || ($bentrydoc.getSpace()==$space))) -- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
