[opencms-dev] custom class for templateone.form

Ian Kavanagh ikavanagh at acm.org
Wed May 2 03:58:53 CEST 2007


Greetings,

I am new to OpenCms and am trying to do the following:
create a new form field type for templateone which allows for a simple 
block of text with no corresponding input field in the form, and have 
this field be an option in the drop-down menu of the form field section 
of the edit dialog for an email form html file.  My idea is that the 
user would select "Text Label" from the "Type" menu, and then enter the 
text to be displayed in the "Label" section.

So far I have created a class called "CmsTextLabel" which extends 
A_CmsField, compiled it, and put the .class file into the: 
/system/modules/org.opencms.frontend.templateone.form/classes/org/opencms/frontend/templateone/form/
directory.

Also, I have created a file "CmsTextLabel.properties" which consists of 
the following text:
FIELDS=textlabel:org.opencms.frontend.templateone.form.CmsTextLabelField
and placed it into the:
/system/modules/org.opencms.frontend.templateone.form/classes/
directory.

I have been trying to figure out the next steps in this process from the 
source code, but posting my question to opencms-dev seemed like the most 
efficient idea.  I haven't found any tutorial that specifically 
addresses this question and would be very grateful for any assistance.

Thanks,
Ian



More information about the opencms-dev mailing list