Re: [PHP] Good grief

2003-02-18 Thread John Taylor-Johnston
Rasmus, If I were going to remanufacture http://www.php.net/manual/en/function.explode.php I would add/edit: $data = "foo:*:1023:1000::/home/foo:/bin/sh"; list($user,$pass,$uid,$gid,$gecos,$home,$shell) = explode(":",$data); echo $user."".$pass."".$uid."".$gecos."".$home."".$shell; Thanks agai

Re: [PHP] Good grief

2003-02-18 Thread John Taylor-Johnston
Rasmus, >You probably want just $db and $table Yes I do. I need to learn a little more about declaring arrays & its syntax. I figured I was declaring an array called "list". Then ... :) Copied & tinkered from: http://www.php.net/manual/en/function.explode.php Thanks! John -- John Taylor-Johns

Re: [PHP] Good grief

2003-02-18 Thread Rasmus Lerdorf
What is $list supposed to be? You probably want just $db and $table there. -Rasmus On Wed, 19 Feb 2003, John Taylor-Johnston wrote: > Yawn of frustration. > > $dbtable = "ccl.ccl_main"; > > list($db,$table) = explode(".",$dbtable); > echo $dbtable.''.$list[$db].''.$list[$table].''; > echo $dbta

[PHP] Good grief

2003-02-18 Thread John Taylor-Johnston
Yawn of frustration. $dbtable = "ccl.ccl_main"; list($db,$table) = explode(".",$dbtable); echo $dbtable.''.$list[$db].''.$list[$table].''; echo $dbtable."".$list[$db]."".$list[$table].""; I stumped :) $list[$db]shows nothing $list[$table] shows nothing Ok, newbie time :( What's wrong? -