Jahia in English > Tutorial

0 (0 Good)
0 (0 Bad)

Tutorial

by  Twinkle_Toes »  2016/08/23 11:25

Hello. I'm using Ubuntu 14, and I download Jahia SDK(Digital Experience Manager SDK) from your site, and run it by following instruction.

I have problems with a tutorial next video about jahia: https://www.youtube.com/watch?v=cFzKxAaQgAQ&index=10&list=PLCi1wJLT02zhNX8RxsvK8vvF9PN8FIZoK .

1. It was all good until I started to work on view of component, where were used tag "JCR:NodePropertyRenderer"(46th minute of video). The result was stack trace with the following head(sorry about format, I don't know how to paste it correctly):

org.apache.jasper.JasperException: /mynt_employee/html/employee.jsp(30,2) PWC6032: Unable to load tag handler class "org.jahia.taglibs.jcr.node.JCRPropertyCustomRendererTag" for tag "jcr:nodePropertyRenderer"
org.jahia.services.render.RenderException: org.apache.jasper.JasperException: /mynt_employee/html/employee.detail.jsp(33,2) PWC6032: Unable to load tag handler class "org.jahia.taglibs.jcr.node.JCRPropertyCustomRendererTag" for tag "jcr:nodePropertyRenderer"

 

2. Also I tried to do next part of tutorial, there was about detail view of component and link between views(51st minute of video). In this part I got next result - link seems broken with message:

"Error

An error has occurred during processing. A mail notification has been sent to the Administrator."

and near it:

"Error: default"

and tens pages of system status information.

 

3. In the next part of tutorial(59th minute) I got the same result as in first, but about tag "template:module" with next stack trace:

org.apache.jasper.JasperException: /mynt_companyDivision/html/companyDivision.jsp(23,2) PWC6032: Unable to load tag handler class "org.jahia.taglibs.template.include.ModuleTag" for tag "template:module"
org.jahia.services.render.RenderException: org.apache.jasper.JasperException: /mynt_companyDivision/html/companyDivision.jsp(23,2) PWC6032: Unable to load tag handler class "org.jahia.taglibs.template.include.ModuleTag" for tag "template:module"

 

Can someone explain or help to fix this problems?

Twinkle_Toes
Number of messages  6
Not registered
0 (0 Good)
0 (0 Bad)

Re: Tutorial

by  jordannroussel »  2016/08/23 11:31

Hello,

 

You should recompile/redeploy your module. You can do this directly in the Studio by clicking on the small gears under the tabs allowing you to select "Files", "Templates", ... or by using directly Maven on your sources, "mvn clean install" command line on the folder containing your pom.xml, then use the administration panel to redeploy your module.

Even though you normally do not need to recompile your module when modifying a view, you should do so the first time that your module is using a new taglib, as this will add the package of the taglib in your MANIFEST.mf, allowing your module to use it.

  • Re: Tutorial
    2016/08/23 11:31

    jordannroussel <p>Hello,</p> <p>&nbsp;</p> <p>You should recompile/redeploy your module. You can do this directly in the Studio by clicking on the small gears under the tabs allowing you to select &quot;Files&quot;, &quot;Templates&quot;, ... or by using directly Maven on your sources,&nbsp;&quot;mvn clean install&quot; command line on the folder containing your pom.xml, then use the administration panel to redeploy your module.</p> <p>Even though you normally do not need to recompile your module when modifying a view, you should do so the first time that your module is using a new taglib, as this will add the package of the taglib in your MANIFEST.mf, allowing your module to use it.</p>

  • Number of messages  13
    Registration date Aug 23, 2016
    0 (0 Good)
    0 (0 Bad)

    Re: Re: Tutorial

    by  Twinkle_Toes »  2016/08/23 11:43

    Thank you very much! It fix 1st and 3rd problems. Don't you know why link doesn't work in 2nd problem?

    Twinkle_Toes
    Number of messages  6
    Not registered
    0 (0 Good)
    0 (0 Bad)

    Re: Re: Re: Tutorial

    by  jordannroussel »  2016/08/23 11:57

    Thank you very much! It fix 1st and 3rd problems. Don't you know why link doesn't work in 2nd problem?

    Few things to check :

    - has your content-template being defined as "Can be used by default" ? Otherwise you need to specify in your link the name of the content-template to use, something like "${url.base}${currentNode.path}.nameOfTheContentTemplate.html"

    - is your link similar to the following : <a href="${currentNode.url}">...</a> ?

     

    If you still have the issue, please share your logs, it will be easier to diagnosis.

     

  • Re: Re: Re: Tutorial
    2016/08/23 11:57

    jordannroussel <blockquote> <p>Thank you very much! It fix 1st and 3rd problems. Don&#39;t you know why link doesn&#39;t work in 2nd problem?</p> </blockquote> <p>Few things to check :</p> <p>- has your content-template being defined as &quot;Can be used by default&quot; ? Otherwise you need to specify in your link the name of the content-template to use, something like &quot;${url.base}${currentNode.path}.<strong>nameOfTheContentTemplate</strong>.html&quot;</p> <p>- is your link similar to the following : &lt;a href=&quot;<strong>${currentNode.url}</strong>&quot;&gt;...&lt;/a&gt; ?</p> <p>&nbsp;</p> <p>If you still have the issue, please share your logs, it will be easier to diagnosis.</p> <p>&nbsp;</p>

  • Number of messages  13
    Registration date Aug 23, 2016
    0 (0 Good)
    0 (0 Bad)

    Re: Re: Re: Re: Tutorial

    by  Twinkle_Toes »  2016/08/23 12:19

    Thank you very much! It fix 1st and 3rd problems. Don't you know why link doesn't work in 2nd problem?

    Few things to check :

    - has your content-template being defined as "Can be used by default" ? Otherwise you need to specify in your link the name of the content-template to use, something like "${url.base}${currentNode.path}.nameOfTheContentTemplate.html"

    - is your link similar to the following : <a href="${currentNode.url}">...</a> ?

     

    If you still have the issue, please share your logs, it will be easier to diagnosis.

     

    No, my template was not defined as "Can be used by default". Now I make it defined so and it works. Thank you

     

     

    Twinkle_Toes
    Number of messages  6
    Not registered
    0 (0 Good)
    0 (0 Bad)

    Tutorial problem #4

    by  Twinkle_Toes »  2016/08/23 13:24

    Hello again, I continue work with the tutorial and have a problem again. This is on 59th minute of video, this part about child nodes and tag <module:...>. Somewhy my component's view of company division, which is parent node of employee, doesn't contains any button for adding new employee. This is my definitions.cnd file:

    <jmix = 'http://www.jahia.org/jahia/mix/1.0'>
    <jnt = 'http://www.jahia.org/jahia/nt/1.0'>
    <mix = 'http://www.jcp.org/jcr/mix/1.0'>
    <mymix = 'http://www.mydomain.org/mix'>
    <mynt = 'http://http://www.smile.fr/'>

    [mynt:employee] > jnt:content, mix:title, mymix:acmeComponent
     - firstName (string)
     - lastName (string)
     - jcr:title (string)
     - biography (string, richtext)
     - photo (weakreference, picker[type='image'])
     - jobTitle (string, choicelist[resourceBundle]) = 'employee' < 'employee', 'assistant', 'consultant', 'director'
     - nationality (string, choicelist[country])
     - birthdate (date, datepicker)
     - supervisor (weakreference) < 'mynt:employee'

    [mymix:acmeComponent] > jmix:droppableContent mixin

    [mynt:companyDivision] > jnt:content, mix:title, mymix:acmeComponent
     - jcr:title (string)
     + * (mynt:employee)

     

    and this is view for companyDivision(companyDivision.jsp):

    <%@ page language="java" contentType="text/html;charset=UTF-8" %>
    <%@ taglib prefix="template" uri="http://www.jahia.org/tags/templateLib" %>
    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
    <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
    <%@ taglib prefix="jcr" uri="http://www.jahia.org/tags/jcr" %>
    <%@ taglib prefix="ui" uri="http://www.jahia.org/tags/uiComponentsLib" %>
    <%@ taglib prefix="functions" uri="http://www.jahia.org/tags/functions" %>
    <%@ taglib prefix="query" uri="http://www.jahia.org/tags/queryLib" %>
    <%@ taglib prefix="utility" uri="http://www.jahia.org/tags/utilityLib" %>
    <%@ taglib prefix="s" uri="http://www.jahia.org/tags/search" %>
    <%--@elvariable id="currentNode" type="org.jahia.services.content.JCRNodeWrapper"--%>
    <%--@elvariable id="out" type="java.io.PrintWriter"--%>
    <%--@elvariable id="script" type="org.jahia.services.render.scripting.Script"--%>
    <%--@elvariable id="scriptInfo" type="java.lang.String"--%>
    <%--@elvariable id="workspace" type="java.lang.String"--%>
    <%--@elvariable id="renderContext" type="org.jahia.services.render.RenderContext"--%>
    <%--@elvariable id="currentResource" type="org.jahia.services.render.Resource"--%>
    <%--@elvariable id="url" type="org.jahia.services.render.URLGenerator"--%>

    <h2>${currentNode.properties['jcr:title'].string}</h2>
    <c:forEach items="${jcr:getChildrenOfType(currentNode, 'mynt:employee')}" var = "employee">
      <template:module node="${employee}" view="default"/>
    </c:forEach>

    <c:if test="${renderContext.editMode}">
      <tempate:module path="*"/>
    </c:if>

     

    Does anybody know what is the problem? I also tried without tag <c:if>, the result is the same.

    Twinkle_Toes
    Number of messages  6
    Not registered
    Contact
    Share
    Feedback

    Get in touch

    Whether you are a current user or if you are just evaluating Jahia, we are here to help.

    Contact us

    Share this page