Hi,<br><br>I followed the tutorial at : <a href="http://www.wdogsystems.com/opencms/opencms/demos/structured_content_editing.html" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.wdogsystems.com/opencms/opencms/demos/structured_content_editing.html</a><br>
<br>but it seems there is a problem. When i create a new File using the structured content, an exception occured :<br>java.lang.NullPointerException
at org.opencms.xml.content.CmsXmlContent.getContentDefinition(CmsXmlContent.java:625)
at org.opencms.xml.content.CmsXmlContent.<init>(CmsXmlContent.java:127)
<br>...<br><br>Here is my opencms-modules.xml :<br>...<br><resourcetypes><br> <type class="org.opencms.file.type.CmsResourceTypeXmlContent" name="DemoType" id="7001"><br>
<param name="schema">/system/modules/mymodule/schemas/sample_article.xsd</param><br> </type><br> </resourcetypes><br> <explorertypes><br>
<explorertype name="DemoType" key="fileicon.DemoType" icon="xmlcontent.gif" reference="xmlcontent"><br> <newresource page="structurecontent" uri="newresource_xmlcontent.jsp?newresourcetype=DemoType" order="7001" /><br>
<accesscontrol><br> <accessentry principal="GROUP.Administrators" permissions="+r+v+w+c"/><br> <accessentry principal="GROUP.Projectmanagers" permissions="+r+v+w+c"/><br>
<accessentry principal="GROUP.Users" permissions="+r+v+w+c"/><br> </accesscontrol><br> </explorertype><br> </explorertypes><br>
...<br><br>And here my /system/modules/mymodule/schemas/sample_article.xsd :<br><xsd:schema xmlns:xsd="<a href="http://www.w3.org/2001/XMLSchema">http://www.w3.org/2001/XMLSchema</a>"<br> elementFormDefault="qualified"><br>
<br> <xsd:include schemaLocation="opencms://opencms-xmlcontent.xsd" /><br> <xsd:element name="DemoTypes"<br> type="OpenCmsDemoTypes" /><br><br> <xsd:complexType name="OpenCmsDemoTypes"><br>
<xsd:sequence><br> <xsd:element name="DemoType"<br> type="OpenCmsDemoType" minOccurs="0"<br> maxOccurs="unbounded" /><br>
</xsd:sequence><br> </xsd:complexType><br><br> <xsd:complexType name="OpenCmsDemoType"><br> <xsd:sequence><br> <xsd:element name="Title" type="OpenCmsString" /><br>
<xsd:element name="Teaser" type="OpenCmsString"<br> maxOccurs="3" /><br> <xsd:element name="Text" type="OpenCmsHtml" /><br>
</xsd:sequence><br> <xsd:attribute name="language" type="OpenCmsLocale"<br> use="required" /><br> </xsd:complexType><br></xsd:schema><br><br>
<br>I tried to configure the workspace.properties in classes/mymodules/ (and even adding the following lines in __property/workspace.properties...) :<br>fileicon.DemoType = Sample Systems Article<br>title.DemoType = Create a new Sample Systems Article<br>
<br>I really don't know what I do wrong... i have an OpenCMS 7.0.4 and all is correct when i restart my server... no error in Tomcat logs...<br><br>help... please... lol<br><br><br><div><span class="gmail_quote">2008/4/9, Vikrama Sanjeeva <<a href="mailto:viki.sanjeeva@gmail.com">viki.sanjeeva@gmail.com</a>>:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>Hi,</div>
<div> You are trying to create structured xml type. Better follow this link of how to: <a href="http://www.wdogsystems.com/opencms/opencms/demos/structured_content_editing.html" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.wdogsystems.com/opencms/opencms/demos/structured_content_editing.html</a></div>
<div> </div>
<div>elements folder -- use to keep "elements" used in your website. Like header, footer, any thing u consider "an-element-in-your-wesbite"</div>
<div>pages folder -- for e.g: you have a news box, and on clicking "more" link of news in this box, detailed news page will open. This detailed new page template can be placed in pages folder.</div>
<div> </div>
<div> </div>
<div>remember, both folders are not any specific keywords in OpenCms. You can use any name you like.</div>
<div> </div>
<div>Bye,</div>
<div>Viki.<br><br></div><div><span class="e" id="q_1193396a2ef68e33_1">
<div class="gmail_quote">On Wed, Apr 9, 2008 at 4:31 PM, Territorio Jordan-V. <<a href="mailto:jordan.territorio@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">jordan.territorio@gmail.com</a>> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;">Thanks Georgi !<br><br>I saw in project the schemas directory which contains xsd files. The documentation says that xsd files are used to "standardize" content of xml files... but i'm lost, i've created the sample.xsd as in the doc, but if i create an xml file from scratch, the edition fails, launching a fu....ing exception ^^<br>
<br>My real problem in the module creation is there :<br>I try to make a module from scratch, and a website using this module (a web portail with login page, where users have access to some information).<br>I noticed that if I create a new "structured content" in my site, the edition fails. So I think that i have to create a file which will inform the workspace of "how organize content for this file". But don't what to do or how associate my structured content file to an xsd or an xml file from my module or something klike that...<br>
<br>Maybe i'm not clear... (i'm french, so it could explain that my english is not very explicit :P)<br><br>
<div><span class="gmail_quote">2008/4/9, Georgi Naplatanov <<a href="mailto:gosho@oles.biz" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">gosho@oles.biz</a>>:</span>
<div>
<div></div>
<div>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hello, Territorio Jordan-V.<br><br>The elements folder in the module, usually contains jsps which are used<br>
in the template(s) to render menus, news, jobs etc.<br><br>The module's folders (under /system/modules) is not visible for user who<br>should edit content of the site only and you should not create pages in<br>modules folder.<br>
<br>I saw jsps in pages folder for some opencms modules which makes some<br>work with posted data. The mail form from template one is one of these<br>examples.<br><br>HTH<br><br>Best regards<br>Georgi<br><br><br>Territorio Jordan-V. wrote:<br>
> Hi all !!<br>><br>> As ever, i'm a newbie and i try to learn the better way to create a real<br>> OpenCMS Module. So my question is, what directory for what pages...<br>><br>> I know that (but not sure)<br>
> resources : to put images or css style, so the graphical ressources<br>> templates : the jsp templates to organize datas on the screen<br>> classes : for properties and Java classes uses<br>> lib : for specials librairies used<br>
><br>> But for those i don't know :<br>> elements/<br>> pages/<br>><br>> I've seen that some pages in the demo uses elements to organize a type of<br>> content so i think you have to create jsp to organize just one type of data<br>
> (but I don't know how to proceed)<br>> So for pages i've no idea...<br>><br>> does someone know more about it, because on wiki i didn't found any explicit<br>> description?<br>><br>> Cheers,<br>
> Jordan<br>><br>><br>><br>><br><br>> ------------------------------------------------------------------------<br>><br>><br>> _______________________________________________<br>> This mail is sent to you from the opencms-dev mailing list<br>
> To change your list options, or to unsubscribe from the list, please visit<br>> <a href="http://lists.opencms.org/mailman/listinfo/opencms-dev" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.opencms.org/mailman/listinfo/opencms-dev</a><br>
<br><br>_______________________________________________<br>This mail is sent to you from the opencms-dev mailing list<br>To change your list options, or to unsubscribe from the list, please visit<br><a href="http://lists.opencms.org/mailman/listinfo/opencms-dev" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.opencms.org/mailman/listinfo/opencms-dev</a><br>
</blockquote></div></div></div><br><br clear="all">
<div>
<div></div>
<div><br>-- <br>TERRITORIO Jordan-Victor<br>Ingénieur d'Intégration Java<br>TEAMLOG – Ingenieurs 2000<br><br>+33 6 30 66 54 69<br><a href="mailto:jot@teamlog.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">jot@teamlog.com</a> </div>
</div><br><br>_______________________________________________<br>This mail is sent to you from the opencms-dev mailing list<br>To change your list options, or to unsubscribe from the list, please visit<br><a href="http://lists.opencms.org/mailman/listinfo/opencms-dev" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.opencms.org/mailman/listinfo/opencms-dev</a><br>
</blockquote></div><br>
</span></div><br><br>
_______________________________________________<br>
This mail is sent to you from the opencms-dev mailing list<br>
To change your list options, or to unsubscribe from the list, please visit<br>
<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://lists.opencms.org/mailman/listinfo/opencms-dev" target="_blank">http://lists.opencms.org/mailman/listinfo/opencms-dev</a><br></blockquote></div><br><br clear="all">
<br>-- <br>TERRITORIO Jordan-Victor<br>Ingénieur d'Intégration Java<br>TEAMLOG – Ingenieurs 2000<br><br>+33 6 30 66 54 69<br><a href="mailto:jot@teamlog.com">jot@teamlog.com</a>