> -----Original Message----- > From: Shawn McKenzie [mailto:[EMAIL PROTECTED]] > Sent: 20 February 2003 05:55 > > While debugging my code, that seems to work fine, I see > hundreds of these > notices, many different ones with different offset numbers > same line number. > > Notice: Undefined offset: 2 in > D:\apps\www\test\themes\Family\includes\autotheme.inc.php on line 275 > > I would like to know what the notice pertains to (offset?) > Here's the code: > > $commands is an associative array, $tmpparts and $tmpcmds are > integer index > arrays. > > $i = 0; // Line 270 > while($i != count($tmpparts)) { > $content = "?>".$tmpparts[$i]; > eval($content); > foreach($command as $name => $cmds) { > if($tmpcmds[$i] == $name) {
Here, the offset is $i -- it's telling you that there is no $i element in the array $tmpcmds. > $docmd = $cmds; > eval($docmd); > } > } > $i++; > } // Line 281 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: [EMAIL PROTECTED] Tel: +44 113 283 2600 extn 4730 Fax: +44 113 283 3211 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php