Tema: mail en php
Ver Mensaje Individual
  #2 (permalink)  
Antiguo 19/11/2014, 15:31
Avatar de pateketrueke
pateketrueke
Modernizr
 
Fecha de Ingreso: abril-2008
Ubicación: Mexihco-Tenochtitlan
Mensajes: 26.399
Antigüedad: 17 años
Puntos: 2534
Respuesta: mail en php

Tu problema no tiene que ver con "mail", tienes problemas graves de sintaxis.

Observa las diferencias:
Código PHP:
Ver original
  1. // MAL
  2. class Foo {
  3.   public $candy = '';
  4.  
  5.   public function __construct($value) {
  6.     $this->$candy = $value;
  7.   }
  8.  
  9.   public function getCandy() {
  10.     return $candy;
  11.   }
  12.  
  13.   public function fun() {
  14.     mail(getCandy());
  15.   }
  16. }
  17.  
  18. // BIEN
  19. class Bar {
  20.   public $candy = '';
  21.  
  22.   public function __construct($value) {
  23.     $this->candy = $value;
  24.   }
  25.  
  26.   public function getCandy() {
  27.     return $this->candy;
  28.   }
  29.  
  30.   public function fun() {
  31.     mail($this->getCandy());
  32.   }
  33. }

Por favor, consulta el manual: http://php.net/manual/es/language.oop5.php
__________________
Y U NO RTFM? щ(ºдºщ)

No atiendo por MP nada que no sea personal.