How to run Zend framework?

0 like 0 dislike
78 views
Can't pick up the project after the "death day"
There is a bug via the WEB (You don't have permission to access /php-bin/php/index.php on this server.)

In the logs (AH01630: client denied by server configuration: /home/php-bin-isp-php70/voishunter/php)
Already worn out and don't know what the problem is...

I attach the vhost

ServerName on-the-go.eu ServerAlias www.on-the-go.eu DocumentRoot /home/voishunter/data/www/on-the-go.eu/public SetEnv APPLICATION_ENV "development" ServerAdmin webmaster@on-the-go.eu DirectoryIndex index.html index.php AddDefaultCharset off SuexecUserGroup voishunter voishunter CustomLog /home/httpd-logs/on-the-go.eu.access.log combined ErrorLog /home/httpd-logs/on-the-go.eu.error.log SetHandler application/x-httpd-php5 ScriptAlias /php-bin/ /home/php-bin-isp-php70/voishunter/ AddHandler application/x-httpd-php5 .php .php3 .php4 .php5 .phtml Action application/x-httpd-php5 /php-bin/php ServerName on-the-go.eu ServerAlias www.on-the-go.eu DocumentRoot /home/voishunter/data/www/on-the-go.eu/public SetEnv APPLICATION_ENV "development" ServerAdmin webmaster@on-the-go.eu DirectoryIndex index.html index.php AddDefaultCharset off SSLEngine on SSLCertificateFile "/var/www/httpd-cert/voishunter/on-the-go.eu.crt" SSLCertificateKeyFile "/var/www/httpd-cert/voishunter/on-the-go.eu.key" SSLCertificateChainFile "/var/www/httpd-cert/voishunter/on-the-go.eu.ca" SSLHonorCipherOrder on SSLProtocol +TLSv1 +TLSv1.1 +TLSv1.2 SSLCipherSuite EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH SuexecUserGroup voishunter voishunter CustomLog /home/httpd-logs/on-the-go.eu.access.log combined ErrorLog /home/httpd-logs/on-the-go.eu.error.log SetHandler application/x-httpd-php5 ScriptAlias /php-bin/ /home/php-bin-isp-php70/voishunter/ AddHandler application/x-httpd-php5 .php .php3 .php4 .php5 .phtml Action application/x-httpd-php5 /php-bin/php Options +Includes -ExecCGI RewriteEngine on AllowOverride All Require all granted RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R,L] 
by | 78 views

2 Answers

0 like 0 dislike
Carefully read and translate the message, we are talking about lack of access.
In the file index.php put only
\r<?php<br/>phpinfo();
?>
and make sure you have a web server and everything connected with it is working properly.
Check all paths and file permissions.
by
0 like 0 dislike
Registration and class autoloading for ZF3 now is via composer.

Was for ZF2 index.php:
<?php\r/**\r* This makes our life easier when dealing with paths. Everything is relative\r* to the application root now.\r*/\rchdir(dirname(__DIR__));\r// Decline static file requests back to the PHP built-in webserver\rif (php_sapi_name() === 'cli-server' && is_file(__DIR__ . parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH))) {\rreturn false;\r}\r// Setup autoloading\rrequire 'init_autoloader.php';\r// Run the application!\rZend\\Mvc\\Application::init(require 'config/application.config.php')->run();


Was for ZF3 index.php:
<?php\ruse Zend\\Mvc\\Application;\ruse Zend\\Stdlib\\ArrayUtils;\r/**\r* This makes our life easier when dealing with paths. Everything is relative\r* to the application root now.\r*/\rchdir(dirname(__DIR__));\r// Decline static file requests back to the PHP built-in webserver\rif (php_sapi_name() === 'cli-server') {\r$path = realpath(__DIR__ . parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH));\rif (__FILE__ !== $path && is_file($path)) {\rreturn false;\r}\runset($path);\r}\r// Composer autoloading\rinclude __DIR__ . '/../vendor/autoload.php';\rif (! class_exists(Application::class)) {\rthrow new RuntimeException(\r"Unable to load application.\"\r. "- Type `composer install` if you are developing locally.\"\r. "- Type `vagrant ssh -c 'composer install'` if you are using Vagrant.\"\r. "- Type `docker-compose run zf composer install` if you are using Docker.\"\r);\r}\r// Retrieve configuration\r$appConfig = require __DIR__ . '/../config/application.config.php';\rif (file_exists(__DIR__ . '/../config/development.config.php')) {\r$appConfig = ArrayUtils::merge($appConfig, require __DIR__ . '/../config/development.config.php');\r}\r// Run the application!\rApplication::init($appConfig)->run();
by

Related questions

0 like 0 dislike
4 answers
asked May 3, 2019 by vetsinen
0 like 0 dislike
7 answers
0 like 0 dislike
1 answer
0 like 0 dislike
2 answers
0 like 0 dislike
1 answer
110,608 questions
257,187 answers
0 comments
40,796 users