Php Error Loging, I'm new to PHP so I try some of the stuff I read about... |
||
Welcome to the Zymic webmaster forums. Our forums are here to provide people the free ability to discuss a range of websites related topics such as design, development coding and marketing.
In order to post you will need to register for a zymic account or if you already have one simply login by using the form on the left.
Zymic Webmaster Forums Zymic Free Web Hosting Zymic Free Web Hosting - General Discussion & Help |
||
![]() |
Php Error Loging, I'm new to PHP so I try some of the stuff I read about... |
||
Jul 9 2012, 06:22 AM
Post
#1
|
|
|
Newbie ![]() Group: Members Posts: 13 Joined: 13-January 12 Member No.: 225,500 |
Hello,
I was playing around with different ideas, methods, etc. to log errors. So I was reading the following tutorial: http://www.spunkyjones.com/tracking-php-errors/ So I executed this code: <h3><?php echo $_SERVER['DOCUMENT_ROOT']; ?></h3> but that seemed to cause a lock on my account because I could upload files but they would not display and the site I was working on isn't updating visually. Also, I try to upload a new directory and got a 404 error. Apologies Thanks. Hello, I was playing around with different ideas, methods, etc. to log errors. So I was reading the following tutorial: http://www.spunkyjones.com/tracking-php-errors/ So I executed this code: <h3><?php echo $_SERVER['DOCUMENT_ROOT']; ?></h3> but that seemed to cause a lock on my account because I could upload files but they would not display and the site I was working on isn't updating visually. Also, I try to upload a new directory and got a 404 error. Apologies Thanks. Now the site is back up but it doesn't record my error logging. I'm tying different methods: error_log($error_details, 3, "./logs/errors.log"); file_put_contents("./logs/my-errors.log", $error_details, FILE_APPEND | LOCK_EX); both methods work on a different host but I know Zymic has their own rules. Is file writing not allowed? Thanks. |
|
|
Jul 9 2012, 06:54 PM
Post
#2
|
|
|
Newbie ![]() Group: Members Posts: 13 Joined: 13-January 12 Member No.: 225,500 |
Now, I can't connect to the FTP server
I get the following error: There was a problem connecting to your host or proxy. Please check your server settings and try again. If you are sure you have entered the correct information, please contact your network administrator or the server administrator. [7] Additional information: couldn't connect to host. Thanks |
|
|
Jul 9 2012, 07:08 PM
Post
#3
|
|
|
Newbie ![]() Group: Members Posts: 13 Joined: 13-January 12 Member No.: 225,500 |
|
|
|
Jul 9 2012, 09:29 PM
Post
#4
|
|
|
THE SILENT FORUM NINJA ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: Administrators Posts: 3,712 Joined: 23-January 10 From: on your screen Member No.: 127,507 |
we know we disable it but now its fixed
|
|
|
Jul 9 2012, 10:16 PM
Post
#5
|
|
|
Newbie ![]() Group: Members Posts: 13 Joined: 13-January 12 Member No.: 225,500 |
we know we disable it but now its fixed Okay, thank you. I apologize for any inconvenience I might have cause testing several code snippets. Is file creation disable on the server? I'm trying to store my error logs here: ./logs/errors.log Using: error_log($error_details, 3, "./logs/errors.log"); But the file isn't being created. Thanks. |
|
|
Jul 10 2012, 02:05 AM
Post
#6
|
|
|
THE SILENT FORUM NINJA ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: Administrators Posts: 3,712 Joined: 23-January 10 From: on your screen Member No.: 127,507 |
its cause we disable custom logs to be made
|
|
|
Jul 10 2012, 03:54 AM
Post
#7
|
|
|
Newbie ![]() Group: Members Posts: 13 Joined: 13-January 12 Member No.: 225,500 |
its cause we disable custom logs to be made Okay, thanks. Is there an alternative for users to keep, browse, etc. the errors occurring on their site? I understand why code like this is bad: ini_set('display_errors', 1); error_reporting(E_ALL); Which the server throws an error. But it is great for learning/development but bad for a production site. What I'm trying to say is if the server suppresses some errors from being display and personal error logs are disable. How can people know if their site is working properly or the code they are developing is proper? From the "echo $_SERVER['DOCUMENT_ROOT'];" incident I assume I was trying to access the server error log and not the one for my account which is why I got a lockdown on my account. So, comes back to my original question I guess. Is there an alternative for error management for the end user? Thanks. |
|
|
Jul 11 2012, 09:41 PM
Post
#8
|
|
|
Newbie ![]() Group: Members Posts: 13 Joined: 13-January 12 Member No.: 225,500 |
Okay, thanks. Is there an alternative for users to keep, browse, etc. the errors occurring on their site? I understand why code like this is bad: ini_set('display_errors', 1); error_reporting(E_ALL); Which the server throws an error. But it is great for learning/development but bad for a production site. What I'm trying to say is if the server suppresses some errors from being display and personal error logs are disable. How can people know if their site is working properly or the code they are developing is proper? From the "echo $_SERVER['DOCUMENT_ROOT'];" incident I assume I was trying to access the server error log and not the one for my account which is why I got a lockdown on my account. So, comes back to my original question I guess. Is there an alternative for error management for the end user? Thanks. I'm guessing that is a "No, we don't"? Or a "we are thinking about it, but not ready to disclose it" situation? Thanks. |
|
|
Jul 11 2012, 10:40 PM
Post
#9
|
|
|
THE SILENT FORUM NINJA ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: Administrators Posts: 3,712 Joined: 23-January 10 From: on your screen Member No.: 127,507 |
its a no we wont cause of the resources needed would take away from the users
|
|
|
![]() |
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users) |
||
| 0 Members: | ||
Forum Jump |
||
| Lo-Fi Version | Time is now: 26th May 2013 - 01:52 AM |