<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>Hi,</p>
    <p>I haven't looked at your code in detail. On first sight: Do not
      start the parameters with "?". There's a "&{createPath" that
      should be "${createPath".</p>
    <p>But, going for an alternative you might use <cms:search>:
<a class="moz-txt-link-freetext" href="https://documentation.opencms.org/opencms-documentation/demos/lists-and-detail-pages-ii/">https://documentation.opencms.org/opencms-documentation/demos/lists-and-detail-pages-ii/</a><br>
    </p>
    <p><span style="color: rgb(20, 67, 130); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 13px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: pre-wrap; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(245, 245, 245); text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;"></span>Best,
      Daniel.<br>
      <span style="color: rgb(20, 67, 130); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 13px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: pre-wrap; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(245, 245, 245); text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;"></span></p>
    <div class="moz-cite-prefix">Am 07.02.19 um 18:08 schrieb Андрей
      Диканский:<br>
    </div>
    <blockquote type="cite" cite="mid:1549559325.17840221@f42.i.mail.ru">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <br>
      Hello!<br>
      <br>
      Can you help me with extractiong content from xml files with
      contentload tag?<br>
      <br>
      I have a resource type Direction with following xsd:<br>
      <br>
      <p><xsd:schema xmlns:xsd=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema">"http://www.w3.org/2001/XMLSchema"</a>
        elementFormDefault="qualified"></p>
      <p><xsd:include
        schemaLocation="opencms://opencms-xmlcontent.xsd"/></p>
      <p><xsd:element name="Directions" type="OpenCmsDirections"/></p>
      <p><xsd:complexType name="OpenCmsDirections"><br>
        <xsd:sequence><br>
        <xsd:element name="Direction" type="OpenCmsDirection"
        minOccurs="0" maxOccurs="unbounded"/><br>
        </xsd:sequence><br>
        </xsd:complexType></p>
      <p><xsd:complexType name="OpenCmsDirection"><br>
        <xsd:sequence><br>
        <xsd:element name="Title" type="OpenCmsString" /><br>
        <xsd:element name="Text" type="OpenCmsHtml" /><br>
        <xsd:element name="Image" type="OpenCmsVfsFile" /><br>
        <xsd:element name="Link" type="OpenCmsVarLink" minOccurs="0"
        /><br>
        </xsd:sequence><br>
        <xsd:attribute name="language" type="OpenCmsLocale"
        use="required"/><br>
        </xsd:complexType></p>
      <p><xsd:annotation><br>
        <xsd:appinfo><br>
        <mappings><br>
        <mapping element="Title" mapto="property:Title" /><br>
        <mapping element="Title" mapto="urlName" /><br>
        </mappings><br>
        <defaults><br>
        <default element="Title" value="Add a new title here" /><br>
        <default element="Text" value="Add your text" /><br>
        </defaults><br>
        <layouts><br>
        <layout element="Text" widget="HtmlWidget"
        configuration="downloadgallery" /><br>
        <layout element="Image" widget="ImageGalleryWidget"
        configuration="{useformat:true}" /><br>
        </layouts><br>
        <validationrules/><br>
        <relations/><br>
        <searchsettings containerPageOnly="true"/><br>
        </xsd:appinfo><br>
        </xsd:annotation></p>
      <p></xsd:schema><br>
        <br>
        I also have /sites/OpenCMSTest/service/index.jsp :<br>
      </p>
      <p><%@page buffer="none" session="false"
        trimDirectiveWhitespaces="true" %><br>
        <%@ taglib prefix="cms"
        uri=<a class="moz-txt-link-rfc2396E" href="http://www.opencms.org/taglib/cms">"http://www.opencms.org/taglib/cms"</a> %><br>
        <%@ taglib prefix="fmt"
        uri=<a class="moz-txt-link-rfc2396E" href="http://java.sun.com/jsp/jstl/fmt">"http://java.sun.com/jsp/jstl/fmt"</a> %><br>
        <%@ taglib prefix="fn"
        uri=<a class="moz-txt-link-rfc2396E" href="http://java.sun.com/jsp/jstl/functions">"http://java.sun.com/jsp/jstl/functions"</a> %><br>
        <%@ taglib prefix="c" uri=<a class="moz-txt-link-rfc2396E" href="http://java.sun.com/jsp/jstl/core">"http://java.sun.com/jsp/jstl/core"</a>
        %><br>
        <!doctype html><br>
        <html lang="ru"></p>
      <p><head><br>
        <meta charset="utf-8"><br>
        <meta name="viewport" content="width=device-width,
        initial-scale=1, shrink-to-fit=no"><br>
        <link
href="<cms:link>%(link.weak:/system/modules/my.template/resources/css/main.css</cms:link>"
        rel="stylesheet" type="text/css"><br>
        <title>Заголовок</title><br>
        </head></p>
      <p><body></p>
      <p><header><br>
        </header></p>
      <p><main><br>
        <%-- Define a Solr query --%><br>
        <c:set
        var="solrQuery">?fq=type:Direction&sort=lastmodified
        desc</c:set></p>
      <p><%-- Define a create path --%><br>
        <c:set
        var="createPath">/sites/OpenCMSTest/.content/Direction/</c:set></p>
      <p><%-- Collect the resources --%><br>
        <cms:contentload collector="byContext"
        param="${solrQuery}|createPath=&{createPath}" preload="true"
        ></p>
      <p><c:if test='${info.resultSize != 0}'><br>
        <cms:contentinfo var="info" /> <br>
        <c:if test='${info.resultSize != 0}'><br>
        <h3>Search results </h3><br>
        <cms:contentload editable="false"><br>
        <cms:contentaccess var="content" /><br>
        ${content.Title} <br /><br>
        </cms:contentload><br>
        </c:if><br>
        </c:if><br>
        </cms:contentload></p>
      <p><br>
        </main></p>
      <p><footer><br>
        </footer></p>
      <p><br>
        </body><br>
        </html><br>
        <br>
        Also I have 3 file xml files (Direction-00001.xml,
        Direction-00002.xml, Direction-00003.xml) with content
        in /sites/OpenCMSTest/.content/Direction/ (see the attachment)<br>
        <br>
        When opeining  /sites/OpenCMSTest/service/index.jsp  I'd like to
        extract Titles from xml files an show it in html.<br>
        <br>
        But nothing happens. It seems that there are no search results.<br>
        <br>
        What I'm doing wrong?</p>
      <p><br>
        <br>
      </p>
      <br>
      <br>
      <br>
      <br>
      <br>
      -- <br>
      Andrew
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
This mail is sent to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please visit
<a class="moz-txt-link-freetext" href="http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev">http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev</a>



</pre>
    </blockquote>
    <pre class="moz-signature" cols="72">-- 
Kind Regards,
Daniel.
 
-------------------

Daniel Seidel

Alkacon Software GmbH & Co. KG - The OpenCms Experts                    
<a class="moz-txt-link-freetext" href="http://www.alkacon.com">http://www.alkacon.com</a> - <a class="moz-txt-link-freetext" href="http://www.opencms.org">http://www.opencms.org</a>     </pre>
  </body>
</html>