function visitors_get_mysql_current_timezone in Visitors 8.2
Same name and namespace in other branches
- 8 visitors.module \visitors_get_mysql_current_timezone()
- 7.2 visitors.module \visitors_get_mysql_current_timezone()
- 7 visitors.module \visitors_get_mysql_current_timezone()
- 7.0 visitors.module \visitors_get_mysql_current_timezone()
Get value of MySQL system variable time_zone.
Return value
string
1 call to visitors_get_mysql_current_timezone()
- visitors_mysql_date_format_sql in ./
visitors.module - Set date format for mysql sql query.
File
- ./
visitors.module, line 61 - Logs visitors for your site.
Code
function visitors_get_mysql_current_timezone() {
$query = 'SHOW variables LIKE \'time_zone\'';
return \Drupal::database()
->query($query)
->fetchField(1);
}