Ver Mensaje Individual
  #1 (permalink)  
Antiguo 18/01/2012, 11:14
iovan
 
Fecha de Ingreso: septiembre-2007
Ubicación: PyRoot
Mensajes: 1.515
Antigüedad: 16 años, 7 meses
Puntos: 188
Problema creando proyecto ZEND FRAMEWORK pensado en migrar a hosting.

Hola amigos que tal.

He seguido el tema de GatorV: http://www.forosdelweb.com/f68/confi...abajar-918099/

Pero mi archivo index es así: [se añade de la linea 15 para abajo]

Código PHP:
Ver original
  1. // Define path to application directory
  2. defined('APPLICATION_PATH')
  3.     || define('APPLICATION_PATH', realpath(dirname(__FILE__) . '/../application'));
  4.  
  5. // Define application environment
  6. defined('APPLICATION_ENV')
  7.     || define('APPLICATION_ENV', (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV') : 'production'));
  8.  
  9. // Ensure library/ is on include_path
  10. set_include_path(implode(PATH_SEPARATOR, array(
  11.     realpath(APPLICATION_PATH . '/../library'),
  12. )));
  13.  
  14. /** Zend_Application */
  15. require_once 'Zend/Application.php';
  16.  
  17. // Create application, bootstrap, and run
  18. $application = new Zend_Application(
  19.     APPLICATION_ENV,
  20.     APPLICATION_PATH . '/configs/application.ini'
  21. );
  22. $application->bootstrap()
  23.             ->run();

Es un poco diferente que el que está puesto en el tutorial, y bueno se entiende aquel post es de mas de 6 meses de antigüedad, el Framework de Zend pudo sufrir una actualización.

Por lo que me pregunto:

Si el index esta en un subdirectorio de public

public/subdirectorio/index.php

¿Que es lo que debo hacer para que index.php me muestra la pagina de inicio de Zend Framework.?

P.D: He bajado un directorio en todo, es decir he hecho lo siguiente: [linea 3, linea 11, linea 16]

Código PHP:
Ver original
  1. // Define path to application directory
  2. defined('APPLICATION_PATH')
  3.     || define('APPLICATION_PATH', realpath(dirname(__FILE__) . '/../../application'));
  4.  
  5. // Define application environment
  6. defined('APPLICATION_ENV')
  7.     || define('APPLICATION_ENV', (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV') : 'production'));
  8.  
  9. // Ensure library/ is on include_path
  10. set_include_path(implode(PATH_SEPARATOR, array(
  11.     realpath(APPLICATION_PATH . '/../../library'),
  12. )));
  13.  
  14. /** Zend_Application */
  15. require_once '/../../library/Zend/Application.php';
  16.  
  17. // Create application, bootstrap, and run
  18. $application = new Zend_Application(
  19.     APPLICATION_ENV,
  20.     APPLICATION_PATH . '/configs/application.ini'
  21. );
  22. $application->bootstrap()
  23.             ->run();

===============
EL require_once de la linea 16 me da un problema. Temo que esto no es así por eso les pregunto.

Gracias.