RE: [PHP] general questions

From: Date: Tue, 03 Jun 2003 10:37:51 +0000
Subject: RE: [PHP] general questions
Groups: php.general 
Request: Send a blank email to php-general+get-149924@lists.php.net to get a copy of this message
> -----Original Message----- > From: Dale [mailto:DaleHersh@hotmail.com] > Sent: 02 June 2003 19:43 > > I am new to php and I just have some general questions. > > 1. when you create a new variable such as an integer, is it > automatically > initialized or is it considered empty similar to asp? In PHP, there's really no way to "create" a variable other than by assigning to it for the first time -- until you do so, it just doesn't exist (it's !isset()). You can *reference* a non-existent variable, and you will get the value NULL returned (plus a notice -- not even a warning -- if you have full error reporting switched on). > 2. If I were to create an array and filled the array with a > Boolean value, a > string, and an integer what type would the array take on? Array() ;) (More specifically, each element of the array would have its own type.) Cheers! Mike --------------------------------------------------------------------- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Graham Building, Leeds Metropolitan University, Beckett Park, LEEDS, LS6 3QS, United Kingdom Email: m.ford@lmu.ac.uk Tel: +44 113 283 2600 extn 4730 Fax: +44 113 283 3211

« previous php.general (#149924) next »