2
votes

I have a production environment working and I would like to know which errors or problems takes place on it which I can not reproduce in my testing environment.

For it, I am trying to make use of the error.log located in cakephp/app/tmp/ folder but I am not able to understand some of those errors or even know where exactly in the code do they take place.

For example:

2013-07-24 10:26:49 Error: [MissingActionException] Action TablesController::fancybox() could not be found.

#0 C:\inetpub\wwwroot\lib\Cake\Routing\Dispatcher.php(186): Controller->invokeAction(Object(CakeRequest))

#1 C:\inetpub\wwwroot\lib\Cake\Routing\Dispatcher.php(161): Dispatcher->_invoke(Object(TablesController), Object(CakeRequest), Object(CakeResponse))

#2 C:\inetpub\wwwroot\app\webroot\index.php(92): Dispatcher->dispatch(Object(CakeRequest), Object(CakeResponse)) #3 C:\inetpub\wwwroot\index.php(42): require('C:\inetpub\wwwr...') #4 {main}

Where is the error coming from? Where am I suppose to to be calling the fancybox() function? In which file and line? I can not trace it with those indications.

Is there any way to read this properly? Am I missing something?

1
I always add the url and the referrer to my error logs. This way its easier to find the source of the issue and how to reproduce it in order to fix it: github.com/dereuromark/tools/blob/master/Lib/Error/…mark
please tag questions with the version of cake you're usingAD7six
2.2 But i guess this behavior is similar in other versions too.Alvaro
it's not helpful to label your questions with versions of cake you aren't using.AD7six

1 Answers

1
votes

Where is the error coming from?

The error message reports that TablesController::fancybox() could not be found

That means there is a request for a url of the form /tables/fancybox/.... was made.

Most likely this is a 404 request generated by a js library loaded by the page. To identify these errors - simply open e.g. chrome's network panel in developer tools and reload the page. Anything in red indicates a request for something that returned an error - and something to fix.

The information of what is making the request will also be in the apache access/error log - the referer is the initiator responsible for making these erroneous requests.