RE: [SLUG] host header name in PHP?

From: Robert Ahrendt (robert.ahrendt@verizon.net)
Date: Thu Mar 27 2003 - 14:50:27 EST


2 ways,
<?php echo("$HTTP_HOST") ?>
or
<?php echo("$SERVER_NAME")?>
but $SERVER_NAME gets the name from your httpd.conf file
where $HTTP_HOST is actually from the environment vars
Hope this helps
Robert

-----Original Message-----
From: slug@lists.nks.net [mailto:slug@lists.nks.net]On Behalf Of pwgrant
Sent: Thursday, March 27, 2003 8:43 AM
To: SLUG List (E-mail)
Subject: [SLUG] host header name in PHP?

How can php echo out the host header name?

In asp it could be
<% response.write (request.servervariables("HTTP_HOST") ) %>



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 17:18:28 EDT