Ver Mensaje Individual
  #6 (permalink)  
Antiguo 16/08/2010, 09:43
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
Respuesta: ayuda con mvc y oop

Como te comento $_POST y $_GET son súper globales tu las puedes leer dentro, verifica este ejemplo:
Código PHP:
Ver original
  1. <?php
  2. class Algo
  3. {
  4.        public function doSomething()
  5.        {
  6.                 echo $_POST['foo'];
  7.        }
  8. }
  9.  
  10. if (strtolower($_SERVER['REQUEST_METHOD']) == 'post') {
  11.         $something = new Algo();
  12.         $something->doSomething();
  13. }

Saludos.