[Logo] Infoglue - Official Forum
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Messages posted by: Anonymous
Forum Index » Profile for Anonymous » Messages posted by Anonymous
Error on line 64, column 41 in default/user_posts_show.htm topics.get(post.topicId) is undefined. It cannot be assigned to topic The problematic instruction: ---------- ==> assignment: topic=topics.get(post.topicId) [on line 64, column 41 in default/user_posts_show.htm] ---------- Java backtrace for programmers: ---------- freemarker.core.InvalidReferenceException: Error on line 64, column 41 in default/user_posts_show.htm topics.get(post.topicId) is undefined. It cannot be assigned to topic at freemarker.core.Assignment.accept(Assignment.java:111) at freemarker.core.Environment.visit(Environment.java:196) at freemarker.core.MixedContent.accept(MixedContent.java:92) at freemarker.core.Environment.visit(Environment.java:196) at freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:160) at freemarker.core.Environment.visit(Environment.java:351) at freemarker.core.IteratorBlock.accept(IteratorBlock.java:95) at freemarker.core.Environment.visit(Environment.java:196) at freemarker.core.MixedContent.accept(MixedContent.java:92) at freemarker.core.Environment.visit(Environment.java:196) at freemarker.core.Environment.process(Environment.java:176) at freemarker.template.Template.process(Template.java:232) at net.jforum.JForum.processCommand(JForum.java:233) at net.jforum.JForum.service(JForum.java:200) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at net.jforum.util.legacy.clickstream.ClickstreamFilter.doFilter(ClickstreamFilter.java:59) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) Messages posted by Anonymous
Author Message
Something that has bugged me (and quite a few clients) for a long time is the fact that you can't remove values from all checkboxes on a property by unchecking them and saving. If you try that the old value(s) will remain. Same thing goes for text fields and text areas; you can't empty them by deleting the text and saving. In both these instances you have to use the "garbage can"-button next to the property. This is quite counterintuitive, and I have a proposition for a fix for it.

The old code in the class ViewSiteNodePageComponentsAction (methods updateComponentProperty around line 1017 and updateComponentProperties around line 1194) looks like this:



My modified code looks like this:



I just removed the condition that states the property must have a value which is not an empty string if it's going to be saved in the database.
With my fix the value will be saved in the database even if the value is empty, thus overwriting the old value, which is what most people would expect it to do.
In the old solution, properties with empty values were just skipped and thus the old value remained in the database.
As far as I can tell, my fix seems to work as expected, but maybe I'm missing some important point. Anybody have any thoughts on this?
[Logo] Infoglue - Official Forum
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 

Information
 

An error has occurred.

For detailed error information, please see the HTML source code, and contact the forum Administrator.

Error on line 64, column 41 in default/user_posts_show.htm
topics.get(post.topicId) is undefined.
It cannot be assigned to topic
 
Forum Index
Powered by JForum 2.1.8 © JForum Team