public function day($value = null)
    {
        if ($value !== null) {
            if ($value > 31 || $value < 1) {
                $this->day = 1;
            } else {
                $this->day = $value;
            }
        }
        return $this->day;
    }
public function day($value = null)
    {
        if ($value !== null) {
            if ($value > 31 || $value < 1) {
                $this->day = 1;
            } else {
                $this->day = $value;
            }
        }
        return $this->day;
    }
public function day ( $ value = null ) { if ( $ value !== null ) { if ( $ value > 31 || $ value < 1 ) { $ this -> day = 1 ; } else { $ this -> day = $ value ; } } return $ this -> day ; }
Set the day field of the date object

@param int the day
@return int the day
Set the day field of the date object