|
|
|
||||
|
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() |
|
|||||||
| Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
|
Thread Tools |
|
|
#1 |
|
Confirmed User
Join Date: Apr 2004
Location: Montreal
Posts: 799
|
I just did what I saw oin php.net to report display PHP's errors.
I also tried 98345394 other variants but no luck. anybody knows how to displays error in PHP ? ( I don't have acces to files, I'm on Virtual Hosting for now)
__________________
I have nothing to advertise ... yet. |
|
|
|
|
|
#2 |
|
Confirmed User
Join Date: May 2004
Posts: 886
|
Can you maybe post some of your code??
|
|
|
|
|
|
#3 |
|
Confirmed User
Join Date: Apr 2004
Location: Montreal
Posts: 799
|
Well ...
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>Insert tcg</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body bgcolor="C6C6C6" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0"> <? error_reporting(E_ALL); then the rest of my code ... ?>
__________________
I have nothing to advertise ... yet. |
|
|
|
|
|
#4 |
|
Confirmed User
Join Date: Apr 2004
Location: Montreal
Posts: 799
|
All I get is a blank page ... (When I have an error in my code)
__________________
I have nothing to advertise ... yet. |
|
|
|
|
|
#5 |
|
Confirmed User
Join Date: May 2004
Location: SW Palm Bay, Florida
Posts: 1,323
|
Hi,
What you need is config.inc just save this code as config.inc and include at the top of your php pages. Code:
<?php
// This script sets the error reporting and logging for the site.
//error_reporting (0); // Production level
error_reporting (E_ALL); // Development level
// Use my own error handling function.
function my_error_handler ($e_number, $e_message, $e_file, $e_line) {
$message = 'An error occurred in script ' . $e_file . ' on line ' . $e_line . ": $e_message";
//error_log ($message, 1, '[email protected]'); // Production (send email)
echo '<font color="red">', $message, '</font>'; // Development (print the error in red)
}
set_error_handler('my_error_handler');
?>
__________________
subarus. |
|
|
|
|
|
#6 |
|
Confirmed User
Join Date: Apr 2004
Location: Montreal
Posts: 799
|
Thanks ! Working like a charm!!!
__________________
I have nothing to advertise ... yet. |
|
|
|
|
|
#7 |
|
Confirmed User
Join Date: May 2004
Location: SW Palm Bay, Florida
Posts: 1,323
|
You're welcome bro.
__________________
subarus. |
|
|
|