Unnamed
public text v1 · immutable $row['note'] = preg_replace_callback('/\[(\*|\/|_|\-)(.+)\]/U',
create_function('$matches', '
switch ($matches[1]) {
case "*":
return "<b>" . $matches[2] . "</b>";
case "/":
return "<i>" . $matches[2] . "</i>";
case "_":
return "<u>" . $matches[2] . "</u>";
case "-":
return "<s>" . $matches[2] . "</s>";
}
'), $row['note']);