Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Errors with PHP & Weblogic Server

Tags:

php

weblogic

We have set up Weblogic to be able to run PHP, this link was used as a guide http://archive.oreilly.com/cs/user/view/cs_msg/25690. We can successfully use PHP albeit only 5.3.9.

One thing that I am having trouble with is displaying all of PHPs errors. When PHP errors in some circumstances it just shows the server error:

Error 500--Internal Server Error From RFC 2068 Hypertext Transfer Protocol -- HTTP/1.1: 10.5.1 500 Internal Server Error The server encountered an unexpected condition which prevented it from fulfilling the request.

I have a local version of PHP (5.6.4) with the same phpinfo() outputs for display_errors => STDOUT => STDOUT and error_reporting => 32767 => 32767 and it will output the errors.

A quick example of errors it won't display are say I get a function name wrong or mistype a language construct like echo, I'll get the server error not the parse error: message: line.

I've never used PHP on weblogic before, so I'm not sure of what this problem is or how to fix it?

like image 971
Jonnny Avatar asked Sep 23 '15 10:09

Jonnny


People also ask

Where are PHP errors?

The location of the error log file itself can be set manually in the php. ini file. On a Windows server, in IIS, it may be something like "'error_log = C:\log_files\php_errors. log'" in Linux it may be a value of "'/var/log/php_errors.

How do I check PHP errors?

Quickly Show All PHP Errors The quickest way to display all php errors and warnings is to add these lines to your PHP code file: ini_set('display_errors', 1); ini_set('display_startup_errors', 1); error_reporting(E_ALL);


1 Answers

Jonnny, are you sure there was no previous error_log setup in your php.ini?

I did a test install of 5.3.9 and got C:\WINDOWS\temp\php-errors.log What does phpinfo() say for the error_log and log_errors directives?

If you want parse errors to be returned to the browser (via stdout) then the value for error_log must be blank or just ensure error_log is not set anywhere

This was my default php.ini and when I checked the log it was was working, including parse errors.

log_errors=On
error_log="C:\WINDOWS\temp\php-errors.log"
like image 73
Steve E. Avatar answered Oct 23 '22 23:10

Steve E.