Solved

Display actual error in code....?

Posted on 2006-07-24
5
182 Views
Last Modified: 2011-09-20
Hi all,
Is there anyway to have PHP display the actual line of code causing problems, rather than just a line number?

0
Comment
Question by:fox_statton
5 Comments
 
LVL 5

Accepted Solution

by:
floorman67 earned 250 total points
ID: 17167795
no php wont do that for you via script, but the error code and line nubmber help you ALOT in tracking down the problem.

it is easy to find the line number with any script editor that segments and lists the code line number by line number.

I use Web Builder 2005 ... http://www.blumentals.net/webuilder/

they have a free trial you can test out.

I am sure there are free ons around that do the same thing or similar.

0
 
LVL 29

Assisted Solution

by:TeRReF
TeRReF earned 250 total points
ID: 17168128
You could use debug_backtrace() to provide you with extra information. You can add it in a trigger_error() event.
http://php.net/debug_backtrace
http://php.net/trigger_error
0
 
LVL 12

Expert Comment

by:AmigoJack
ID: 17168548
oh please... have you ever considered pressing CTRL+G in notepad/editor?

more helpful could only be self-healing-php-scripts ;-)
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
These days socially coordinated efforts have turned into a critical requirement for enterprises.
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

912 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now