$cuenta = count($el_loop);$el_loop[$cuenta-1] = str_replace('),' , ')' , $el_loop[$cuenta-1]);foreach( $el_loop as $mi_loop ) { /* Código */ }