Brimbox Logo Brimbox Version 2.3.4 Released


This method (a reverse function) converts user and PHP datetime to server and database and datetime.

Class: bb_main, called as $main

File: bb_main.php (php)


function rconvert_date($date, $format = "Y-m-d")


$server_date = $main->rconvert_date($date);

Returns: date converted into database and server datetime from local user datetime.

Note: method uses constants DB_TIMEZONE and USER_TIMEZONE from file bb-config.php

Parameter: $date (string, valid php date)
Database date in acceptable format for php (several formats work).

Parameter: $format (string, php date format)
Standard php date format. See

Updated: 2016-06-16