Ver Mensaje Individual
  #1 (permalink)  
Antiguo 04/06/2010, 11:46
Avatar de juanito1712
juanito1712
 
Fecha de Ingreso: mayo-2010
Ubicación: Valencia
Mensajes: 1.124
Antigüedad: 14 años
Puntos: 66
Pregunta existe algo como ereg_replace pero multiple?

digamos que tengo esto
Código PHP:
Ver original
  1. $texto=ereg_replace("{b}","<b>",$texto);
  2. $texto=ereg_replace("{/b}","</b>",$texto);
  3.  
  4. $texto=ereg_replace("{u}","<u>",$texto);
  5. $texto=ereg_replace("{/u}","</u>",$texto);
  6.  
  7. $texto=ereg_replace("{i}","<i>",$texto);
  8. $texto=ereg_replace("{/i}","</i>",$texto);

hay alguna funcion en php que haga eso pero todo de una? nose, que se le puedan pasar todos los valores en la misma funcion