Open the PHP project site, the page appears blank

Source: Internet
Author: User
Keywords Php
Php

Environment: apache,php with Apple's own
Items are placed under the default documentroot: "/library/webserver/documents" below

DocumentRoot of the new virtualhost: "/library/webserver/documents/myproject/public"
There are index.phtml files in the public directory

Cat public/index.php

/**

    • This makes we are easier when dealing with paths. Everything is relative
    • To the application root now. */

ChDir (DirName (__dir__));

Decline static file requests back to the PHP built-in webserver

if (php_sapi_name () = = = ' Cli-server ' && is_file (__dir__. Parse_url ($_server[' Request_uri '], Php_url_path))) {
return false;
}

Setup autoloading
Require ' init_autoloader.php ';

Run the application!
Zend\mvc\application::init (Require ' config/application.config.php ')->run ();

When you open a Web page, a blank appears, and the error message is
[Error] Failed to load Resource:the Server responded with a status of $ (Internal server Error)

Then I added a phpinfo () to the index.php and the page shows the Phpinfo page

Above my situation and problem is this, ask you the great God help me to see the problem is out where! Thanks a lot!!
Added: Viewed/var/log/apache2/erro_log
Display error asseticwriter:unable to create a directory

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.