Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

NewBie Simple Question.

Status
Not open for further replies.

zick79

Technical User
Joined
May 19, 2003
Messages
40
Location
CA
<?
/* source code */
print $HTTP_HOST;
?>


This is what I am getting after runing this php file in browser:

Notice: Undefined variable: HTTP_HOST in C:\Inetpub\ftproot\jurek\ on line

I tried print , echo but still the same result. What I am doing wrong, this is vary simple code? Please help

Thanks
 
PS. I use PHP ver. PHP Version 4.3.1 and IIS 5 and wind 2000 serv
 
[tt]register_globals[/tt] is probably set to [tt]off[/tt] in [tt]php.ini[/tt]. Either set it to [tt]on[/tt], which could impose security issues (see or use [tt]$_SERVER['HTTP_HOST'][/tt].

//Daniel
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top