473,396 Members | 2,111 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Suppressing full path dump on interpreter warnings?

I read somewhere that showing the full path during an error dump is a "bad
thing":

/dir1/dir2/somedir/script_that_died.php

Like during a parse error or a warning from the interpreter. How can I tell
the PHP interpreter to show only the script filename and if possible, one or
two directories above?

Thanks.
Jul 25 '05 #1
1 1487
On Mon, 25 Jul 2005 11:42:37 -0400, "Robert Oschler"
<no************@nospam.com> wrote:
I read somewhere that showing the full path during an error dump is a "bad
thing":

/dir1/dir2/somedir/script_that_died.php

Like during a parse error or a warning from the interpreter. How can I tell
the PHP interpreter to show only the script filename and if possible, one or
two directories above?


Disable automatic error display and create your own error handler --
then put in whatever you want. For all public facing websites, I
always create a "friendly" error page anyway that doesn't go into
detail. Only during debugging would I want the errors fully
displayed.

Jul 25 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Adam Smith | last post by:
Hope this is the right news group!! I did a server upgrade and at the same time did a mysql update from 4.0.12 to Ver 12.22 Distrib 4.0.16 mach1# mysql --version mysql Ver 12.22 Distrib...
40
by: Dave Hansen | last post by:
Please note crosspost. Often when writing code requiring function pointers, it is necessary to write functions that ignore their formal parameters. For example, a state machine function might...
4
by: Dots | last post by:
I have a class library with a method called getpath(). I want to be able to get the full path of a folder and write some files to the (my_files_dir) folder. A console application will use this...
2
by: stevie.greenslade | last post by:
'Lo all. I have a simple question I'd like help on. :] How, if at all, would one go about suppressing the console window that flashes up when you make at system() call in your C++ program? I'm...
7
by: Mike OKC | last post by:
The Directory.GetFiles method will bring back the file name including the path. I just want the file name, not the path. For Each strFile In Directory.GetFiles(strLocalPath)...
6
by: Michael B Allen | last post by:
Hi, I have a macro that looks like the following: #define MMSG msgno_loc0(LOC0, LOC1) && msgno_mmsg0 which if used in some code like: MMSG("foo=%s", foo);
1
by: Claire | last post by:
Visual Studio 2005 In my setup project, I've needed to include external setup files required to install a manufacturers smart card reader drivers. This collection of files includes those needed...
5
by: jerrygarciuh | last post by:
Hello, I have a couple of PHP scripts I use via cron and from the CLI. They always produce warnings like PHP Warning: Module 'mysql' already loaded in Unknown on line 0 PHP Warning: Module...
5
by: johnericaturnbull | last post by:
Hi - I am very new to python. I get this random core dump and am looking for a good way to catch the error. I know the function my core dump occurs. Is there any error catching/handling that I...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.