{"id":3394,"date":"2014-03-23T13:51:43","date_gmt":"2014-03-23T13:51:43","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2014\/03\/23\/problem-about-cq5-collection-of-common-programming-errors\/"},"modified":"2014-03-23T13:51:43","modified_gmt":"2014-03-23T13:51:43","slug":"problem-about-cq5-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2014\/03\/23\/problem-about-cq5-collection-of-common-programming-errors\/","title":{"rendered":"problem about cq5-Collection of common programming errors"},"content":{"rendered":"<ul>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/3e75c47c5e999d83357037fbafcecb8f?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nGreg Whitaker<br \/>\nmaven-2 pom.xml slf4j cq5<br \/>\nI am new to slf4j and have a few questions. Where do log files go when using the slf4j.Logger in cq5I am currently using eclipse to build the jar files.Can anyone please tell where can I see log file.I could not see that log information in crx-quickstart\/log path.Do I need to configure anything in pom.xml to specify log file location?<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/i.stack.imgur.com\/NMHOy.png?s=32&amp;g=1\" \/><br \/>\nzaxeer<br \/>\njava cq5 sling<br \/>\nI have seen in adobe API documentation QueryBuilder Service which can be called by URLs for many query options, this returns JSON based responses. Very well. I wan to use this in java API. I have found some examples and tried in eclipse but some thing i dont know that how to get the Service &#8220;sling&#8221; as in given code below: OR in other words how to make a QueryBuilder Java object.Any specific JAR i needed or i need to install Apache SLING on my PC i am not sure any one who can share this will be h<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/af337c5469bcd9be568782c157438992?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nViren Pushpanayagam<br \/>\ncq5 aem<br \/>\nHow do I programmatically (in a JSP) set as &#8216;selected&#8217; an item in a dropdown? Following is my code. &lt;cq:include path=&#8221;.\/country&#8221; resourceType=&#8221;foundation\/components\/form\/dropdown&#8221; \/&gt;I have a list of countries in the dropdown and want a country to be selected based on a value passed to the JSP.<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/2271eda4ebce1e2c9c42a4f705e339c7?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nbeautifulday<br \/>\ncq5<br \/>\nI&#8217;m trying to start by double clicking on cq-quickstart-5.4.0.jar. I&#8217;ve changed the name to cq-author-4502.jar. But after starting it, I&#8217;m getting below error in server.log &#8211; I&#8217;m running on Windows 7 and java version is 1.6.0_1506.08.2013 00:22:15 *MARK * server: Server start06.08.2013 00:22:15 *MARK * servletengine: Servlet engine start 06.08.2013 00:22:15 *MARK * servletengine: Servlet container start 06.08.2013 00:22:15 *WARN * servletengine: Unable to determine hostname of 192.168.1.102. 06<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/9c9c2c5fc83c72e6dc9d78e06739bdbd?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nBj\u00f6rn Pollex<br \/>\njava adobe osgi jmx cq5<br \/>\nI&#8217;m trying to get the HeapMemoryUsage of the publish server from the author instance. I attached the code of the servlet which gets called below.In the exception you can see that we get a NullPointerException at Line 88 which is JMXConnectorFactory.connect(serviceUrl).From Jconsole or by running it from a test class (local with main method) it functions without any problems.The Exception:29.11.2012 15:01:17.407 *ERROR* [127.0.0.1 [1354197677403] GET \/bin\/cqdashboard HTTP\/1.1] org.apache.sli<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/i.stack.imgur.com\/bYMlQ.jpg?s=32&amp;g=1\" \/><br \/>\nDelmon Young<br \/>\njquery cq5<br \/>\nI&#8217;m pretty new to adobe cq5 and I&#8217;m using clientlibs to load in my jquery. The problem is whenever I load in my jQuery I get an anonymous function error specifically this:Uncaught TypeError: Property &#8216;$&#8217; of object [object Object] is not a function clientlibs.js:7 (anonymous function)My jQuery is pretty straightforward:$(function() {\/\/do some stuff });Any idea why I&#8217;m getting this error it has to be something simple I&#8217;m missing. Thanks!<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/08d1ca0ceb9ff7b1406704bdaa275422?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nAngry Spartan<br \/>\njavascript cq5<br \/>\nI have no idea how this happened, but clicking Edit in design mode for par (text component) generates a script error in widget.js. All other components work fine in when you click to edit them.Here are console dumps of the errors:Firefox: Error: TypeError: this.items.items[(i + 1)] is undefined Source File: http:\/\/localhost:4502\/libs\/cq\/ui\/widgets.js Line: 147092The full block of code in question:if (title != this.items.items[i + 1].title) {\/\/ next title is different &gt;&gt; breakbreak; }Chrom<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/c933c4598ae4dc80ea4456334ed73648?s=128&amp;d=identicon&amp;r=PG\" \/><br \/>\nLee Abraham<br \/>\njavascript cq5<br \/>\nI&#8217;m trying to develop a custom xtype that extends the tags xtype defined in \/libs\/cq\/tagging\/widgets\/source\/widgets\/TagInputField.jsI have the function defined in another fileCQ.tagging.customTagInputField = CQ.Ext.extend(CQ.TagInputField, { \/*A whole bunch of code here *\/ });CQ.Ext.reg(&#8220;customtags&#8221;, CQ.tagging.customTagInputField);Yet every time I try to boot up a page containing my custom widget I get an error in my console sayingTypeError: sp is undefinedspp = sp.prototype;According to the al<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/b46628a4675dd1b982db0dbc6897cb23?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nuser2379691<br \/>\ncq5<br \/>\nWe are trying to upgrade from CQ 5.4 to 5.6 and while working with sprinkles.. I&#8217;m getteting JS error as undefined for CQ.themes.Dialog.SPRINKLESAny suggestions around would be appreciated&#8230;<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/5c0000343ab0b7a1cafff30ff696491c?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\ndiffa<br \/>\ndeployment maven-3 cq5 aem<br \/>\nI am trying to deploy AEM with maven, so I follow this tutorial. When I run the command mvn clear package, I get the following error:C:\\workspace\\myproject\\app&gt;mvn clean package [INFO] Scanning for projects&#8230; [WARNING] The POM for com.day.jcr.vault:maven-vault-plugin:jar:0.0.10 is missing , no dependency information available [ERROR] The build could not read 1 project -&gt; [Help 1] [ERROR] [ERROR] The project com.uum:app:1-SNAPSHOT (C:\\workspace\\myproject\\app\\pom.xml ) has 3 errors [ERROR<\/li>\n<\/ul>\n<p>Web site is in building<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Greg Whitaker maven-2 pom.xml slf4j cq5 I am new to slf4j and have a few questions. Where do log files go when using the slf4j.Logger in cq5I am currently using eclipse to build the jar files.Can anyone please tell where can I see log file.I could not see that log information in crx-quickstart\/log path.Do I [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-3394","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/3394","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=3394"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/3394\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=3394"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=3394"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=3394"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}