PHP/Utility Function/exit

Материал из Web эксперт
Перейти к: навигация, поиск

void exit ( [mixed status] ) terminates execution of a script, and is an alias of the exit( ) function.

 
$db = open_database( ) OR die("Couldn"t open database!");



void exit ( [mixed status] ) terminates execution of the script

 
if ($password != "frosties") {
            print "Access denied.";
            exit( ); // note: ( ) is optional
    }