$cn = preg_replace('/^[0-9]+([^0-9])/', '\\1', preg_replace('/[^-a-zA-Z0-9_|^{}[\]\\\\]/', '', $bbuserinfo["username"]));$output .= '<a href="http://www.somesite.com/chat&user='.$cn.'">Join Chat!</a>';