Skip to content

Instantly share code, notes, and snippets.

@DirkWolke
Created August 31, 2016 14:58
Show Gist options
  • Save DirkWolke/2b4f60802b93fdfd9715b479450dd806 to your computer and use it in GitHub Desktop.
Save DirkWolke/2b4f60802b93fdfd9715b479450dd806 to your computer and use it in GitHub Desktop.
#TYPO3 add required message for empty field in Extension #cal width #fe_editing
# add message marker in title
plugin.tx_cal_controller.view.create_event.title_stdWrap {
dataWrap = <div class="form-group"><label for="title">%%%WHAT%%%:</label>###TITLE_REQUIRED### ###TITLE_CONSTRAIN###<input class="form-control" type="text" value="|" size="40" name="tx_cal_controller[title]" id="title" /></div>
htmlSpecialChars = 1
}
# add rule for message if field empty
plugin.tx_cal_controller.rights.create.event.fields.title {
required = 0
constrain {
1 {
rule = regexp
regexp = /.+/
message = TEXT
message {
dataWrap = <span class="constrain">Bitte füllen Sie das Feld Titel aus</span>
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment