Re: Replacement Question.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Wow! Thanks.. That works great. Just one small hitch though. After it prints all of the data properly, it adds one more '$date' on the end which gets printed as '12/31/69 7:00:pm'. Is there a way to do all groups - 1 ?

Bob Palma
bpalma@xxxxxxxxx

Duncan Hill wrote:

On Wednesday 20 April 2005 15:22, Bob Palma typed:

I have a database field that I need to read and do some conversion on.
Here is what the raw data from the database looks like:

--
1084751309jpenaDisney Vignette Fleximon disk utilization
alert C:\ at 85%1084799703bpalmafixed.1084799713bpalmaclosed
--


Are the group delimiters different from the field delimiters?

Ie, can you do:
$array_of_groups = explode('group_delim', $in_string);
foreach ($array_of_groups as $i) {
 $array_of_fields = explode('field_delim', $i);
 $date = date('m/j/y g:i:a', $array_of_fields[0]);
 print "$date {$a_o_f[1]}<br />{$a_o_f[2]}<br /><br />\n";
}

YMMV of course.


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


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux