You are here: Re: $_SERVER not working « PHP Programming Language « IT news, forums, messages
Re: $_SERVER not working

Posted by Puneet on 11/16/04 11:50

Nope.. If i use your code.. then I am getting this..

PHP Notice: Undefined index: HTTP_HOST in C:\Program Files\Apache
Group\Apache2\htdocs\_debug_tmp.php on line 5


If i use
Print "Host is : $_SERVER ['HTTP_HOST']";

The I am getting..
Host is : Array ['HTTP_HOST']

What's wrong...
Please help...

Bent Stigsen wrote:
> Puneet wrote:
> [snip]
> > All the uper globals are not working. They
> > just come back with e.g Array ['HTTP_HOST']... Can any body help?
>
> Sound like you need some curly brackets:
>
> echo "{$_SERVER['HTTP_HOST']}";
>
> --
> /Bent

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация