Templating¶
Customize the output:¶
Per default, all templates are stored in
typo3conf/ext/sf_register/Resouces/Private.
Copy this Folder into the fileadmin and edit the templates you want to change. Don’t forget to set the path to this new templates folder with
plugin.tx_sfregister.templateRootPath = fileadmin/extension_templates/sf_register/Private
The Plugins can take the path as well.
Viewhelper for templates:¶
Birthdate with three select boxes¶
<register:form.rangeSelect start="1" end="31" property="dateOfBirthDay"/>
-
<register:form.rangeSelect start="1" end="12" property="dateOfBirthMonth"/>
-
<register:form.rangeSelect start="1960" end="2011" property="dateOfBirthYear"/>
Single select with radio buttons¶
<f:form.radio property="gender" value="1"/> <f:translate key="gender_male"/>
<f:form.radio property="gender" value="2"/> <f:translate key="gender_female"/>
Single select as select box¶
<f:form.select property="gender" options="{
1: '{f:translate(key: \'gender_male\')}',
2: '{f:translate(key: \'gender_female\')}'
}"/>
automatic marking of requried fields¶
<f:render partial="required" arguments="{field: 'gender'}"/>
you get the asterix (*) behind your label, if the required validator is active for this field.