I'm using this but it's replacing single occurances of a new line with <br/><br/>
function nl2br2($string){
$string = preg_replace('/(\r\n){2,}/', '<br/><br/>', $string);
//$string = preg_replace('/[\r\n]/', '<br/>', $string);
return $string;
}
It happens with the first pattern.