Click to See Complete Forum and Search --> : Error City: Warning: Use of undefined


Anon
05-22-2002, 07:02 PM
Upgraded system from NT4 Server Apache 1.3 PHP 4 to Win 2000, iis 5, php 4.2.1.

I have tried non-stop for days to get my existing pages to work again.

I constantly get these error messages

Warning: Use of undefined constant
&
Warning: Undefined index:

----------------------------
I have tried these combinations of systems

Apache 1.3 + All PHP versions 4 to latest
IIS 5 + All PHP versions 4 to latest

can anyone help me corncerning this.

webmaster@netpup.co.uk

Anon
05-24-2002, 12:53 AM
I haven't found the real reason yet, why PHP (since 4.0.4, I guess) wants variables to be declared!

The simplest way to supress it, is to put an '@' before any variable or array, that cause errors, like
@$my_var or
@$array['unknownindex']

Anon
05-25-2002, 12:38 AM
omni httpd server is the best!.

the latest version has php included all ready to run!

Anon
05-27-2002, 06:23 PM
Because you should declare variables before using them. That is good software engineering.

--
I haven't found the real reason yet, why PHP (since 4.0.4, I guess) wants variables to be declared!