Ver Mensaje Individual
  #3 (permalink)  
Antiguo 13/01/2008, 01:19
Avatar de GatorV
GatorV
$this->role('moderador');
 
Fecha de Ingreso: mayo-2006
Ubicación: /home/ams/
Mensajes: 38.567
Antigüedad: 18 años
Puntos: 2135
Re: Funcion Swap (Intercambio) de variables

Solo es cuestion de pasar la REFERENCIA a tu funcion:
Código PHP:
function swap(&$a,&$b)
{
    
$aux=$a;
    
$a=$b;
    
$b=$aux;

Saludos.