Created
July 8, 2013 05:12
-
-
Save umidjons/5946362 to your computer and use it in GitHub Desktop.
Bitrix: Get current site's date and time formats
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<? | |
// выводит текущую дату в формате текущего сайта | |
echo date($DB->DateFormatToPHP(CSite::GetDateFormat("SHORT")), time()); | |
// Возвращает формат времени, указанный в настройках сайта. | |
echo $GLOBALS["DB"]->DateFormatToPHP( CSite::GetTimeFormat() ); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment