<?php
$string = 'Diego:25:RJ';
preg_match('/(?P<nome>\w+):(?P<idade>\d+):(?P<estado>\w+)/', $string , $matches );
echo $matches['nome'] . "\n";
echo $matches['idade'] . "\n";
echo $matches['estado'] . "\n";
PD9waHAKCiRzdHJpbmcgPSAnRGllZ286MjU6UkonOwoKcHJlZ19tYXRjaCgnLyg/UDxub21lPlx3Kyk6KD9QPGlkYWRlPlxkKyk6KD9QPGVzdGFkbz5cdyspLycsICRzdHJpbmcgLCAkbWF0Y2hlcyApOwoKZWNobyAkbWF0Y2hlc1snbm9tZSddIC4gIlxuIjsKZWNobyAkbWF0Y2hlc1snaWRhZGUnXSAuICJcbiI7CmVjaG8gJG1hdGNoZXNbJ2VzdGFkbyddIC4gIlxuIjsK