hi anyangwe,

either define the variables or do what most people do and turn down error
reporting.  see :

  Reporting Errors                                            :
  -------------------------------------------------------------
  http://www.php.net/manual/en/phpdevel-errors.php

pay special attention to E_NOTICE.  for example, the following should give
a similar errors with E_NOTICE on :

  print $array[index]  // Always use quotes, looks for static variable
                       // named 'index' first.  'make' in your case.
                       // sidenote: something like $array[4] is good.

  if ($user == '')     // Use isset or empty or something similar.

  print $notset;       // ""

  if ($sumbit)         // "" or don't depend on submit buttons.

messing with empty variables is okay but use quotes around array index.
always.  except when index is a number (not associative).  it works
without but having php look for static variables first wastes energy and
will cause unexpected results if it happens to exist.

this is set in php.ini through error_reporting setting and also the
following function has useful information within it :

  error_reporting -- set which PHP errors are reported        :
  -------------------------------------------------------------  
  http://www.php.net/manual/en/function.error-reporting.php

anyone have more information to share?  please do.

warm regards,

philip



On Tue, 27 Mar 2001, Anyangwe, Tanwani wrote:

> Warning: Undefined index: make in C:\PHP\Test_Scripts\testdb3.php on line 16
> 
> Warning: Undefined variable: user in C:\PHP\Test_Scripts\testdb3.php on line
> 5
> etc.
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to