php man page for gethostname

Query: gethostname

OS: php

Section: 3

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

GETHOSTNAME(3)								 1							    GETHOSTNAME(3)

gethostname - Gets the host name

SYNOPSIS
string gethostname (void )
DESCRIPTION
gethostname(3) gets the standard host name for the local machine.
RETURN VALUES
Returns a string with the hostname on success, otherwise FALSE is returned.
EXAMPLES
Example #1 A simple gethostname(3) example <?php echo gethostname(); // may output e.g,: sandie // Or, an option that also works before PHP 5.3 echo php_uname('n'); // may output e.g,: sandie ?>
SEE ALSO
gethostbyname(3), gethostbyaddr(3), php_uname(3). PHP Documentation Group GETHOSTNAME(3)
Related Man Pages
gethostname(2) - redhat
sethostname(2) - redhat
sethostname(3) - mojave
gethostname(3p) - suse
sethostname(3) - netbsd
Similar Topics in the Unix Linux Community
regarding gethostname()
gethostnameby_r crashes
gethostname warning