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 MikeeOK on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

undefined variables

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Hi,
This may sound really stupid but is there anyway to stop warning messages about undefined variables appearing when viewing php in browser, or even better, how can i define a variable such as a submit variable i.e.
if ($submit) {...}
I am completely new at this as you may have guessed. The script is running fine apart from the warning and don't want to rock the boat....
 
how about
if (!$submit) {
echo "nothing submitted";
}else {
echo "stuff submitted, doing stuff";
} ***************************************
Party on, dudes!
[cannon]
 
yes.


you must have in the PHP.INI this:

error_reporting = E_ALL & ~E_NOTICE

This shows all the errors except the notices ... that kind of warnings about vars not defined.
Anikin
Hugo Alexandre Dias
Web-Programmer
anikin_jedi@hotmail.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top