Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8636695
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T10:17:29+00:00 2026-06-12T10:17:29+00:00

Possible Duplicate: Reference – What does this error mean in PHP? I had a

  • 0

Possible Duplicate:
Reference – What does this error mean in PHP?

I had a ZF configuration on a local webserver and everything worked just fine.
Now i put it on the internet at my host and when i load the site i get many warnings/ fatal error on the screen. Does anybody have an idea what the reason can be?

Greetings Eric

Example:

Warning: is_readable() [function.is-readable]: open_basedir restriction in effect.
File(/usr/local/reserved///sites/ericversteeg.nl/www/application/../library/Custom/Zend/Application/Resource/View.php) is not within the allowed path(s): (/usr/local/reserved/index.php:/sites/ericversteeg.nl/:/tmp) in /sites/ericversteeg.nl/www/library/Zend/Loader.php on line 198

Warning: is_readable() [function.is-readable]: open_basedir restriction in effect. File(/usr/local/reserved///sites/ericversteeg.nl/www/application/../library/Custom/Zend/Application/Resource/View.php) is not within the allowed path(s): (/usr/local/reserved/index.php:/sites/ericversteeg.nl/:/tmp) in /sites/ericversteeg.nl/www/library/Zend/Loader.php on line 198

And finally the fatal:

Fatal error: Uncaught exception ‘Zend_Controller_Response_Exception’ with message ‘Cannot send headers; headers already sent in /sites/ericversteeg.nl/www/library/Zend/Loader.php, line 198’ in /sites/ericversteeg.nl/www/library/Zend/Controller/Response/Abstract.php:323 Stack trace: #0 /sites/ericversteeg.nl/www/library/Zend/Controller/Response/Abstract.php(341): Zend_Controller_Response_Abstract->canSendHeaders(true) #1 /sites/ericversteeg.nl/www/library/Zend/Controller/Response/Abstract.php(768): Zend_Controller_Response_Abstract->sendHeaders() #2 /sites/ericversteeg.nl/www/library/Zend/Controller/Front.php(992): Zend_Controller_Response_Abstract->sendResponse() #3 /sites/ericversteeg.nl/www/library/Zend/Application/Bootstrap/Bootstrap.php(97): Zend_Controller_Front->dispatch() #4 /sites/ericversteeg.nl/www/library/Zend/Application.php(366): Zend_Application_Bootstrap_Bootstrap->run() #5 /sites/ericversteeg.nl/www/public/index.php(28): Zend_Application->run() #6 {main} thrown in /sites/ericversteeg.nl/www/library/Zend/Controller/Response/Abstract.php on line 323

my index.php :

date_default_timezone_set('Europe/Paris');

// Define path to application directory
defined('APPLICATION_PATH')
    || define('APPLICATION_PATH', realpath(dirname(__FILE__) . '/../application'));

// Define application environment
defined('APPLICATION_ENV')
    || define('APPLICATION_ENV', (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV') : 'production'));

// Ensure library/ is on include_path
set_include_path(implode(PATH_SEPARATOR, array(
    realpath(APPLICATION_PATH . '/../library'),
    get_include_path(),
)));

/** Zend_Application */
require_once 'Zend/Application.php';

// Create application, bootstrap, and run
$application = new Zend_Application(
    APPLICATION_ENV,
    APPLICATION_PATH . '/configs/application.ini'
);
$application->bootstrap()
            ->run();

my bootstrap

class Bootstrap extends Zend_Application_Bootstrap_Bootstrap {

    public function _initAutoloader() {
        $autoloader = new Zend_Application_Module_Autoloader(array(
            'namespace' => '',
            'basePath' => APPLICATION_PATH,
            'fallbackAutoloader' => true
        ));

        return $autoloader;
    }

    protected function _initConfig() {
        Zend_Registry::set('config', new Zend_Config_Ini(
            APPLICATION_PATH . '/configs/application.ini',
            APPLICATION_ENV,
            array('allowModifications' => true)
        ));
        $router = Zend_Controller_Front::getInstance()->getRouter();
        $router->addConfig(new Zend_Config_Xml(APPLICATION_PATH . '/routes.xml'));
    }

    protected function _initDbAdapter() {
        $this->bootstrap('db');
        $db = $this->getResource('db');
        if (!is_null($db)) {
            Zend_Registry::set('db', $db);
        } else {
            throw new Zend_Exception('Cannot connect to database');
        }
    }

    protected function _initSession() {
        $resource = $this->getPluginResource('session');
        Zend_Session::setOptions($resource->getOptions());
        $ns = new Zend_Session_Namespace('Eric_website');
        Zend_Registry::set('session', $ns);
    }

    protected function _initLog() {
        //Zend_Registry::set('logger', new Custom_Zend_Log());

        // Chrome PhpConsole
        if (APPLICATION_ENV == 'development') {
            Custom_PhpConsole::setEnabledOnServer();
            if (Custom_PhpConsole::isEnabledOnClient()) {
                Custom_PhpConsole::start(true, true, dirname(__FILE__));
                //Custom_PhpConsole::$ignoreRepeatedEvents = true;
            }
        }
        // Dummy debug function in case PhpConsole is not used
        if (!function_exists('debug')) {
            function debug() { }
        }
        $logger = new Zend_Log();

        // firebug writer voor development omgeving
        $writer = new Zend_Log_Writer_Firebug();
        $writer->setEnabled(true);
        $logger->addWriter($writer);

        Zend_Registry::set('logger', $logger);
    }

    protected function _initView() {

        // Initialize view
        $view = new Zend_View();
        $view->addHelperPath(APPLICATION_PATH . '/views/helpers/', 'Custom_Zend_View_Helper');
        $view->addScriptPath(APPLICATION_PATH . '/views/scripts/');
        $view->addScriptPath(APPLICATION_PATH . '/views/partials/');
        //$view->headMeta()->appendHttpEquiv('Content-Language', Zend_Registry::get('language'));

        // Add it to the ViewRenderer
        $viewRenderer = Zend_Controller_Action_HelperBroker::getStaticHelper('ViewRenderer');
        $viewRenderer->setView($view);
        $view->doctype('XHTML1_STRICT');

        // Return it, so that it can be stored by the bootstrap
        return $view;
    }

}

and my htaccess is located in the root to ignore public directory on the host:

RewriteEngine On 
RewriteRule ^\.htaccess$ - [F] 
RewriteCond %{REQUEST_URI} =""
RewriteRule ^.*$ /public/index.php [NC,L] 
RewriteCond %{REQUEST_URI} !^/public/.*$
RewriteRule ^(.*)$ /public/$1 
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^.*$ - [NC,L] 
RewriteRule ^public/.*$ /public/index.php [NC,L]
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T10:17:30+00:00Added an answer on June 12, 2026 at 10:17 am

    If your server is controlled by Plesk or similar panel, then it is very usual that open_basedir option is set to your web folder (basically, default behaviour for those panels is to restrict your scripts from accessing file outside of your web folder). But there are many cases when disabling this restriction makes sense and is not abusive, e.g. having a framework outside of any virtual host folder as a single copy to be used by scripts on different hosts.

    You need to add the following text into your vhost.conf (usually residing at /var/www/vhosts/yourdomain.com/httpdocs):

    <Directory /var/www/vhosts/yourdomain.com/httpdocs>
        php_admin_value open_basedir "/var/www/vhosts/yourdomain.com" # or /var/www/vhosts etc., depends on where do you want to include your files from, put top level dir here
        php_admin_flag safe_mode off
    </Directory>
    

    After that, restart your webserver or rebuild its configuration without restart as:

    websrvmng -u –vhost-name=yourdomain.com

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: Reference - What does this error mean in PHP? I am having
Possible Duplicate: Reference - What does this symbol mean in PHP? I have a
Possible Duplicate: Reference - What does this symbol mean in PHP? What's the difference
Possible Duplicate: php == vs === operator Reference - What does this symbol mean
Possible Duplicate: Reference - What does this symbol mean in PHP? Found an image
Possible duplicate of Reference - What does this symbol mean in PHP? What does
Possible Duplicate: Reference - What does this symbol mean in PHP? Is there any
Possible Duplicate: Reference - What does this symbol mean in PHP? In PHP what
Possible Duplicate: Reference - What does this symbol mean in PHP? What does the
Possible Duplicate: Reference - What does this symbol mean in PHP? Consider this code

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.