Changeset 15584 for branches/2.3/include/functions.inc.php
- Timestamp:
- Jun 7, 2012, 12:52:43 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.3/include/functions.inc.php
r15576 r15584 1650 1650 return implode('.', array_slice(explode('.', $version), 0, 2)); 1651 1651 } 1652 1653 /**1654 * return hostname with gethostbyaddr and keep it in database1655 */1656 function get_host($force_update=false)1657 {1658 global $conf;1659 1660 if (!isset($conf['host']) or $force_update)1661 {1662 $conf['host'] = 'undefined';1663 if ($host = @gethostbyaddr($_SERVER['SERVER_ADDR']))1664 {1665 $conf['host'] = $host;1666 }1667 conf_update_param('host', $conf['host']);1668 }1669 return $conf['host'];1670 }1671 1652 ?>
Note: See TracChangeset
for help on using the changeset viewer.