Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. DateTimePlus.php

function DateTimePlus::prepareTime

Prepares the input time value.

Changes the input value before trying to use it, if necessary. Can be overridden to handle special cases.

Parameters

mixed $time: An input value, which could be a timestamp, a string, or an array of date parts.

Return value

mixed The massaged time.

1 call to DateTimePlus::prepareTime()
DateTimePlus::__construct in core/lib/Drupal/Component/Datetime/DateTimePlus.php
Constructs a date object set to a requested date and timezone.

File

core/lib/Drupal/Component/Datetime/DateTimePlus.php, line 429

Class

DateTimePlus
Wraps DateTime().

Namespace

Drupal\Component\Datetime

Code

protected function prepareTime($time) {
    return $time;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal