<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">Hi
everyone,</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">I am an OpenCms beginner.
I am currently using OpenCms 8.0.4. I wanna
create a new Content type for users to drag and
drop.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">I successfully created my
new resource type via the following steps.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">1. Create a module named
my.module.poll under /system/modules/</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">2. Get into
/system/modules/my.module.poll/schemas, create an XSD file to define the schema
named as poll.xsd</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">3. Add my formatter (.jsp
file with formatter tag) under
/system/modules/my.module.poll/formatters</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">4. Go to
opencms_modules.xml file to add two more elements (e.g. resourecetypes and
exploretype)</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">5. Create a
workplace.propertes file to name the label under
/system/modules/my.module.poll/my/module/poll</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">6. Export the module and
publish the module </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">7. Re-start the
tomcat.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">Actually, the new resource
type is created. I have no problem up to now.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">I tried to make the
resource type as the content type. </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">That mean I can use the
drag and drop feature to create a new Poll content in
container</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">2. Go to
/system/modules/my.module.poll</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">2. Create a module config
file named as .config and set the Resource Type information such as Type name,
Folder and Name Pattern</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">3. Go the the folder e.g.
/site/default/flower_en/.content</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">4. Edit the .config file
(adding the newly-created resource type)</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">Now, I went to flower_en
webpage and I can find the Poll content shown in the content list after clicking
"Add Content" icon.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">However, no container
support the newly-created content type.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">That mean, no container is
highlighted to let me drag and drop newly-created Poll
content.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">Please kindly tell me what
I am missing.</span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US"> </span></font></p>
<p class="MsoNormal"><font face="Arial" size="1"><span style="font-family:Arial;font-size:9pt" lang="EN-US">Is my concept correct to
create a new content type?</span></font></p><p class="MsoNormal"><br><font face="Arial" size="1"><span style="font-family:Arial;font-size:9pt" lang="EN-US"></span></font></p><p class="MsoNormal"><font face="Arial" size="1"><span style="FONT-FAMILY:Arial;FONT-SIZE:9pt" lang="EN-US">Thanks for your kind attention.</span></font><br clear="all">
</p><font size="1"><font face="Arial"><br></font></font>-- <br>Best Wishes,<br>Connie Lam<br>