Perfect! That did exactly what I needed.

Now, *ahem*, I thought I knew how to assign variables to the elements in
Array2 but *cough* I'm somewhat befuddled. I've not been able to find
anything in the online php manual. Could you point me in the right direction
for that?

Thank you,

susan

-----Original Message-----
From: CPT John W. Holmes [mailto:[EMAIL PROTECTED]
Sent: Friday, November 14, 2003 3:00 PM
To: Susan Ator; 'Lowell Allen'; PHP
Subject: Re: [PHP] Having fits with input to array

$Array1 = array();
$Array2 = array();

$cmd = " -C $pgm --no-headers -o
pid,fname,state,vsz,start_time,flag,user,cputime,args --cols 200";
$ps = `ps $cmd`;
$Array1 = explode("\n",$ps);
foreach($Array1 as $line)
{ $Array2[] = explode(" ",$line); }

print_r($Array1);
print_r($Array2);

---John Holmes...

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to