$re = '/PAS_BEGIN_0009999(.*?)PAS_END_0009999/s';
$str = 'PAS_BEGIN_0009999
T71_MANUFACTURER_4=98
T71_COLOR_ID_7=000
T71_OS_7=08
PAS_END_0009999
PAS_BEGIN_0009996
T72_VAS_SERVICE_IDENTIFIER_6=
T72_ORDER_NB_7=0003
T72_TECHNOLOGY_7=01
PAS_END_0009996
TPV_BEGIN
PAS_20819001=3600000
TPV_END';
preg_match_all($re, $str, $matches, PREG_SET_ORDER, 0);
// Print the entire match result
var_dump($matches);
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for PHP, please visit: http://php.net/manual/en/ref.pcre.php