Hi Optic Blaze,
I have found the problem. It wasn'd the datatepicker. There was a problem with misspelling in an other field.
I had copied the code from a different page without a datepicker.
Thanks a lot..
Regards Andy
This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
Hi Optic Blaze,
I have found the problem. It wasn'd the datatepicker. There was a problem with misspelling in an other field.
I had copied the code from a different page without a datepicker.
Thanks a lot..
Regards Andy
Hi there,
Good to hear. I worked on the code... mine looks a bit different...but i checked it and it works:
<?php
class Termin extends DataObject {
static $db = array(
'FirstDate' => 'Date',
'DateRange' => 'Varchar',
'Description' => 'HTMLVarchar'
);
function getCMSFields() {
$fields = new FieldList(
$dateField = new DateField('FirstDate', 'FirstDate'),
new HTMLEditorField('Description','Beschreibung'),
new TextField('DateRange','Termin')
);
$dateField->setConfig('showcalendar', true);
$dateField->setConfig('dateformat','dd-MM-yyyy');
return $fields;
}
}