Help: An Error Has Occurred

A Member? Please Login  
type your username and password to login
Date: August 30, 2008, 02:09 AM
234916 members and 135073 Topics
Latest Member: Endalagrorn
Nairaland [Nigerian Forum] Home Help Search Who is currently online? Login Register
Nairaland Forum  |  Technology  |  Programming  |  Help: An Error Has Occurred
Pages: (1) Go Down Send this topic Notify of replies
Author Topic: Help: An Error Has Occurred  (Read 139 views)
nateone (m)
Help: An Error Has Occurred
« on: November 03, 2007, 03:17 AM »

hi house, please, who can explain in detail what is the meaning of this result

An Error Has Occurred

2: Division by zero
File: /home/naijacam/public_html/Sources/Subs.php
Line: 584

happened to my website, can anybody sugest a way to go about it
Kobojunkie
Re: Help: An Error Has Occurred
« #1 on: November 03, 2007, 03:38 AM »

I am thinking the error is that some function tried to divide by zero and that caused an error, as it says there in the exception message you posted.

Quote from: nateone on November 03, 2007, 03:17 AM
hi house, please, who can explain in detail what is the meaning of this result

An Error Has Occurred

2: Division by zero
File: /home/naijacam/public_html/Sources/Subs.php
Line: 584

happened to my website, can anybody sugest a way to go about it

Try stepping through your code to debug it and you may find out where the problem is and fix it.
my2cents (m)
Re: Help: An Error Has Occurred
« #2 on: November 03, 2007, 10:36 AM »

In addition to what Kobo has said:

It is possible that you didn't purposely intend to divide by zero.  There is probably a condition you haven't accounted for in your code which raised this flag at this particular time.  I would modify the code to include a try-catch block.  That way, if the condition ever arises again, your code can crash gracefully.  Depending on what version of PHP you are using, this should be available to you.

Also look at the "@" (error supressor) symbol.  WARNING: This only suppresses error messages but not error detection.  Only use this if you are 100% certain that your program can proceed as usual even if a divide-by-zero does occur.


I hope this helps.
allonym
Re: Help: An Error Has Occurred
« #3 on: November 12, 2007, 08:01 AM »

You don't need to step through your code.  Your error plainly says the problem occurred on line 584 in /home/naijacam/public_html/Sources/Subs.php.  Look at your code on that line and around it.  Why is it dividing by zero?  Fix the problem.
 Pls Read This  A Lifetime Opportunity  Book Your Cisco Ccna,ccnp Exams For Just =n= 20,000 !  Page 2
Pages: (1) Go Up Send Topic to Friend by E-mail Reply 
Google
 
Web www.nairaland.com
Sections: TV/Movies (2) Music/Radio (2) Celebrities Job Talk Jobs/Vacancies (2) Career Talk Romance Books Politics Sports Fashion Travel
Health Schooling Religion General(2) Business Webmaster Programming Computers Phones Cars & Trucks

Links: Page1 Page2 Page3 Page4 Page5 Page6 Page7 Page8 Page9 Page10

Nairaland is owned by Oluwaseun Osewa
Nairaland Forum | Powered by SMF 1.0.12.
© 2001-2005, Lewis Media. All Rights Reserved.