Ver Mensaje Individual
  #1 (permalink)  
Antiguo 22/12/2009, 08:25
Avatar de blogger
blogger
 
Fecha de Ingreso: diciembre-2005
Ubicación: frente al monitor
Mensajes: 398
Antigüedad: 18 años, 4 meses
Puntos: 12
Fatal error en proceso

Hola estoy creando un sitio, y estoy utilizando sesiones y funciones para manejar los formularios, utilizando el ejemplo de aquí http://evolt.org/PHP-Login-System-with-Admin-Features.

Tengo un formulario, con un campo en hidden para verificar en la sesión y llamar a la función, pero me marca el siguiente error:

Fatal error: Call to undefined method Process::procRecreaHist() in process.php on line 39

y en el process.php la linea 39 se ve así:
Código PHP:
  function Process(){ 
      global 
$session
      
/* User submitted login form */ 
      
if(isset($_POST['sublogin'])){ 
         
$this->procLogin(); 
      } 

      
/*Usuario crea uncontenido*/
      
else if(isset($_POST['creahist'])){ 
         
$this->procRecreaHist(); <----- linea 39
      

Pero más abajo tengo definido ese proceso
Código PHP:
   /** 
    * procCreaHist - Crea la historia 
    */ 
   
function procRecreaHist(){ 
      global 
$session$form
      
/* Account edit attempt */ 
      
$retval $session->creaHist($_POST['user'], $_POST['title'], $_POST['code']); 
 
      
/* Account edit successful */ 
      
if($retval){ 
         
$_SESSION['creaHist'] = true
         
header("Location: ".$session->referrer); 
      } 
      
/* Error found with form */ 
      
else{ 
         
$_SESSION['value_array'] = $_POST
         
$_SESSION['error_array'] = $form->getErrorArray(); 
         
header("Location: ".$session->referrer); 
      }

Alguien puede ayudarme, que estoy haciendo mal?
__________________
http://exegesis-biblica.com/