daydreamer Posted November 25, 2008 Share Posted November 25, 2008 I am using this code to prevent output of error code: error_reporting(E_ALL ^ E_NOTICE); ini_set('display_errors', 0); // Hide all error messages from the public ini_set('log_errors', 1); ini_set('error_log', "errorlog.txt"); but I am on shared hosting, and my entire folder and sub folders are all accessible to the public, i do not have read/write access to any other folder on the server. How do I prevent people reading this error log? At the moment I am just giving it a random name instead of errorlog.txt, and directory listing is disabled. Quote Link to comment Share on other sites More sharing options...
revraz Posted November 25, 2008 Share Posted November 25, 2008 htaccess? Also, your host doesnt provide you with a folder that is on the same level as your web folder? I'd switch hosts. Quote Link to comment Share on other sites More sharing options...
daydreamer Posted November 25, 2008 Author Share Posted November 25, 2008 they dont allow me to do .htaccess on the server I am using. I have access to two servers on my one hosting account. One is linux without SSL (but with .htaccess), and the other is windows with SSL functions. My website uses SSL so the linux server is basically unused. I think my only option is to write my own error function and save details into mysql. Quote Link to comment Share on other sites More sharing options...
flyhoney Posted November 25, 2008 Share Posted November 25, 2008 Can you place the error log in a directory a CHMOD it so that the public can not access it? Quote Link to comment Share on other sites More sharing options...
daydreamer Posted November 25, 2008 Author Share Posted November 25, 2008 I cannot change the permissions on any of the folders because it is a windows server and I only have FTP access. Can you place the error log in a directory a CHMOD it so that the public can not access it?Is that what you mean? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.