سؤال

I have installed Xdebug and im runing on Ubuntu OS, Using Apatana as IDE. When i start the debug it is stopping at index.php line no2.

<?php
error_reporting(E_ALL);
// change the following paths if necessary
$yii=dirname(__FILE__).'/../yii/framework/yii.php';   ==> this is the line no 2
$config=dirname(__FILE__).'/protected/config/main.php';

// remove the following lines when in production mode
defined('YII_DEBUG') or define('YII_DEBUG',true);
// specify how many levels of call stack should be shown in each log message
defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);

require_once($yii);
Yii::createWebApplication($config)->run();

i cannot understand what is the reason, any Yii+xdebug expert please help me, do i need to do any extra configurations on aptana like adding libraries ?

هل كانت مفيدة؟

المحلول

Xdebug always stops on the first line of your code. It's up to the IDE to disable this. It is often a "break on the first line" setting. You should be able to turn that off from the menu Tools | Options, click on the PHP icon and uncheck the Stop at the First Line box.

نصائح أخرى

XDebug has break_on_exception parameter which defines case when debugging stops and it has default values such as "Fatal error", "Catchable fatal error", "Warning","Parse error","Notice", "Strict standards", "Deprecated", "Xdebug", "Unknown error".

Just change those to "Fatal error", "Catchable fatal error", "Parse error".

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top