The date of the post, formatted according to the postto user's
preferences.

@return string.
503221
public function get_postdate() {
        global $CFG;

        $postmodified = $this->post->modified;
        if (!empty($CFG->forum_enabletimedposts) && ($this->discussion->timestart > $postmodified)) {
            $postmodified = $this->discussion->timestart;
        }

        return userdate($postmodified, "", \core_date::get_user_timezone($this->get_postto()));
    }
1206670
public function getDate()
    {
        if ($this->hasDatabaseField('Date')) {
            return $this->getField('Date');
        }
        return !empty($this->PublishDate) ? $this->PublishDate : null;
    }
805750
public function Date()
    {
        $formatter = $this->getFormatter(IntlDateFormatter::MEDIUM, IntlDateFormatter::NONE);
        return $formatter->format($this->getTimestamp());
    }
701655
public function getFormattedExpirationDate()
    {
        $date = $this->model->getExpirationDate();

        if ($date instanceof Carbon) {
            $isFuture   = $date->isFuture();
            $translated = $isFuture ? $date->diffForHumans(null, true) : $date->diffForHumans();

            if ($isFuture) {
                $translated = 'in ' . $translated;
            }

            return $translated;
        }

        return '---';
    }
520292
public function dateFilter() {

		// Apply the from date filter.

		$request = $this->getRequest();
		$from = $request->getVar('from');
		$link = $this->Link();
		$separator = '?';
		if($from) {

			// Determine the formatted URL to represent the request filter.

			$date = DBDate::create()->setValue($from);
			$link .= $date->Format('y/MM/dd/');
		}

		// Preserve the category/tag filters if they exist.

		$category = $request->getVar('category');
		$tag = $request->getVar('tag');
		if($category) {
			$link = HTTP::setGetVar('category', $category, $link, $separator);
			$separator = '&';
		}
		if($tag) {
			$link = HTTP::setGetVar('tag', $tag, $link, $separator);
		}

		// Allow extension customisation.

		$this->extend('updateFilter', $link);

		// Request the filtered paginated children.

		return $this->redirect($link);
	}
1370372
public function created_at_formatted()
    {
        return ucfirst($this->dates->make($this->wrappedObject->created_at)->format($this->incidentDateFormat()));
    }
640298
public function getDeathDate(): Date
    {
        foreach ($this->getAllDeathDates() as $date) {
            if ($date->isOK()) {
                return $date;
            }
        }

        return new Date('');
    }
2136
private function getRFC1123DateString() {
        $date = new \DateTime(null, new \DateTimeZone("UTC"));
        return str_replace("+0000", "GMT", $date->format(\DateTime::RFC1123));
    }
877934
protected function getDatetimeFormat()
    {
        if( $this->interval !== '* * * * *' )
        {
            $interval = $this->interval.' ';
        }
        else
        {
            $interval = ( $this->minute    ?? '*' ) . ' '.
                        ( $this->hour      ?? '*' ) . ' '.
                        ( $this->dayNumber ?? '*' ) . ' '.
                        ( $this->month     ?? '*' ) . ' '.
                        ( $this->day       ?? '*' ) . ' ';
        }

        $this->defaultIntervalVariables();

        return $interval;
    }
125256
public function date(WP_Post $post, string $format): string
    {
        Assert::stringNotEmpty($format);

        $postDate = get_the_date($format, $post);

        $this->bailIfInvalidValue($postDate, $post);

        return $postDate;
    }
1361844
public function modifiedTime(WP_Post $post, string $format): string
    {
        Assert::stringNotEmpty($format);

        $postDate = get_the_modified_time($format, $post);

        $this->bailIfInvalidValue($postDate, $post);

        return $postDate;
    }
843468
static public function getDateFormatter()
    {
        if (is_null(self::$service)) {
            $ext = common_ext_ExtensionsManager::singleton()->getExtensionById('tao');
            $service = $ext->getConfig(self::CONFIG_KEY);
            self::$service = $service instanceof DateFormatterInterface
                ? $service
                : new EuropeanFormatter();
        }

        return self::$service;
    }
199871
public function getPostalCode() : ?string 
    {
        if ( ! $this->hasPostalCode()) {
            $this->setPostalCode($this->getDefaultPostalCode());
        }
        return $this->postalCode;
    }
1333549
public function getDatePrettyPrint()
  {
    $date = str_replace('?', '', $this->date);
    $date = explode('.', $date);
    $date = array_filter($date);

    if (count($date) == 2 || count($date) == 3) {
      $month = date('F', mktime(0, 0, 0, $date[1], 1));
      $date = "$month, $date[0]";
    } elseif (count($date) == 1) {
      $date = $date[0];
    } else {
      $date = null;
    }

    return $date;
  }
697739
public String getFormatedDate()
    {
        if(date == null){return "";}
        
        StringBuilder sb = new StringBuilder();
        GregorianCalendar g = new GregorianCalendar();
        g.setTime(date);
        sb.append(String.valueOf(g.get(GregorianCalendar.YEAR))).append("-");
        sb.append(twoDigitFormat(g.get(GregorianCalendar.MONTH) + 1)).append("-");
        sb.append(twoDigitFormat(g.get(GregorianCalendar.DAY_OF_MONTH)));
        
        return sb.toString();
    }
710002
public function getAllDateFormatFlat()
    {
        $aOut     = [];
        $aFormats = $this->getAllDateFormat();

        foreach ($aFormats as $oFormat) {
            $aOut[$oFormat->slug] = $oFormat->example;
        }

        return $aOut;
    }
829558
public function convertToFormattedDbDate()
    {
        $this->setValue(\OxidEsales\Eshop\Core\Registry::getUtilsDate()->formatDBDate($this->rawValue), self::T_RAW);
    }