Sunnysideup\DatefieldSimplified\SimpleDateField
- Author: nicolaas [at] sunnysideup.co.nz To Do: 1. write documenation 2. change $config into NON-static
Synopsis
class SimpleDateField
extends DateField
{
- // members
- private static Boolean $month_before_day = false;
- private static String $default_fancy_date_format = 'j F Y';
- private static String $placeholder_value = '9 nov 1989';
- // methods
- public void __construct()
- public void Field()
- public void setValue()
- public Int ConvertToTSorERROR()
- public String ConverToFancyDate()
Hierarchy
Extends
- SilverStripe\Forms\DateField
Members
private
- $default_fancy_date_format
—
Sunnysideup\DatefieldSimplified\String
The PHP date function formatting for showing the final date. - $month_before_day
—
Sunnysideup\DatefieldSimplified\Boolean
Americans should set this to TRUE. - $placeholder_value
—
Sunnysideup\DatefieldSimplified\String
What would you like the place holder value to be?
Methods
public
- __construct()
- ConverToFancyDate() — Turns user input into a formatted Date or an Error Message ...
- ConvertToTSorERROR() — changes the raw input into TimeStamp Date OR ERROR String
- Field()
- setValue() — Sets the internal value to ISO date format.