You are here

function date_sql_handler::construct in Date 7

Same name and namespace in other branches
  1. 5.2 date_api_sql.inc \date_sql_handler::construct()
  2. 6.2 date_api_sql.inc \date_sql_handler::construct()
  3. 6 date_api_sql.inc \date_sql_handler::construct()

File

date_api/date_api_sql.inc, line 72
SQL helper for Date API.

Class

date_sql_handler
A class to manipulate date SQL.

Code

function construct($date_type = DATE_DATETIME, $local_timezone = NULL) {
  $this->db_type = $this
    ->get_db_type();
  $this->date_type = $date_type;
  $this->db_timezone = 'UTC';
  $this->local_timezone = isset($local_timezone) ? $local_timezone : date_default_timezone();
  date_api_set_db_timezone();
}