Moin!
So richtig wird nicht klar, was Du willst. Ich habe mal das geskriptet, wovon ich annehme, das es das ist, was Du willst:
<?php
## Für die Ausgabe:
if (! empty($_SERVER['DOCUMENT_ROOT']) ) {
header('Content-Type:text/plain');
}
$input_line='sdfghsdfgVAR:0/1/0/2/0/3/0/4/0/0/10/11/12/1/0/1/0/1/2/2/3/2/4/2/5/37/37/28/255/3/0/0/0/0/:VARwrsgthsdrfghs';
if ( preg_match("/VAR:([0-9\/]*?):VAR/", $input_line, $output_array) ) {
print_r($output_array);
#Array
#(
# [0] => VAR:0/1/0/2/0/3/0/4/0/0/10/11/12/1/0/1/0/1/2/2/3/2/4/2/5/37/37/28/255/3/0/0/0/0/:VAR
# [1] => 0/1/0/2/0/3/0/4/0/0/10/11/12/1/0/1/0/1/2/2/3/2/4/2/5/37/37/28/255/3/0/0/0/0/
#)
$a=explode('/', $output_array[1]);
print_r($a);
} else {
echo "Nichts gefunden.\n";
}
Jörg Reinholz