in reply to Golf: Replacing part of a string with "*"
More clean:
$string = '*' x 12 . substr($string,-4); # ************5678 [download]