473,626 Members | 3,221 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

PEAR::Error ? Or else ?

Hello,

Has someone here used the PEAR error handling mechanism, and how useful
did he/her found it ?

I'm a bit newbie with PHP (not with programming...) and currently
working on a small OO framework, I find the lack of an exception
mechanism a bit disturbing, so I wonder how to implement a good error
handling. So any sound advice is welcome !-)

TIA
Bruno

Jul 16 '05 #1
2 3831
I've found it to be very useful along with the PEAR logging module.

Check this article out: http://www.zend.com/zend/tut/tutorial-eckhouse.php

- Justin

"Bruno Desthuilliers" <bd***********@ removeme.free.f r> wrote in message
news:3f******** *************@n ews.free.fr...
Hello,

Has someone here used the PEAR error handling mechanism, and how useful
did he/her found it ?

I'm a bit newbie with PHP (not with programming...) and currently
working on a small OO framework, I find the lack of an exception
mechanism a bit disturbing, so I wonder how to implement a good error
handling. So any sound advice is welcome !-)

TIA
Bruno

Jul 16 '05 #2
Justin wrote:
"Bruno Desthuilliers" <bd***********@ removeme.free.f r> wrote in message
news:3f******** *************@n ews.free.fr...
Hello,

Has someone here used the PEAR error handling mechanism, and how useful
did he/her found it ?

I'm a bit newbie with PHP (not with programming...) and currently
working on a small OO framework, I find the lack of an exception
mechanism a bit disturbing, so I wonder how to implement a good error
handling. So any sound advice is welcome !-)

TIA
I've found it to be very useful along with the PEAR logging module.

Check this article out:
http://www.zend.com/zend/tut/tutorial-eckhouse.php


Lol ! It's that article that made me post this question !-)
Good article BTW, but I wonder if PEAR error handling is not a bit
overcomplicated (sorry, I'm used to Python's exceptions...). Hence my
post...

But well, I guess that whatever I'd make on my own would probably end up
at least equally complex.

Bruno

Jul 16 '05 #3

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

Similar topics

3
2196
by: David | last post by:
I installed the Pear program and set the include path in php.ini to point to the pear dir. I have a program which <? require_once("DB.php"); ?> This produces the error "Class 'PEAR_Error' not found in c:\PHP\pear\PEAR\DB.php on line 868"
0
1907
by: Samuel Zallocco | last post by:
Hi all, I've a problem with PHP5 + PEAR::SOAP. I Have the following 2 script that implements a simple web service: The Server Code running on WinXP + PHP5 + Apache 2.x: ---------------------------------------------------- <?php require_once('SOAP/Server.php'); require_once('SOAP/Disco.php');
0
2037
by: bwhitehd | last post by:
I'm having a problem installing php. The compile seems to go fine, but when it gets to the install step I get the following errors. Does anyone have an idea of what might be the problem? We build our applications under three different environments (Linux i686, Linux x86_64, Solaris 8 Sparc). This is the first of the three on a RHEL 3 system using the current stable versions of the GNU toolchain in a segregated environment. Basically...
0
1171
by: phy1729 | last post by:
When I run any pear command in the shell it returns: Warning: main(PEAR/Config.php): failed to open stream: No such file or directory in pearcmd.php on line 43 Fatal error: main(): Failed opening required 'PEAR/Config.php' (include_path='/usr/lib/php') in /usr/lib/php/pearcmd.php on line 43 I have no idea what this means please help.
4
3691
by: inetquestion | last post by:
php has been configured with the following two configure lines and core's during "make install" on the PEAR section. Is there something simple i'm missing? Any help would be appreciated. Environment: Solaris 9 php 5.2.1 GNU Make 3.81 gcc 4.1.1
5
4514
by: Dan Fulbright | last post by:
I'm trying to install PHP 5.2.2 on Windows, but I keep getting errors when running go-pear.bat: mmap cache can't open phar://go-pear.phar/index.php mmap cache can't open phar://go-pear.phar/PEAR/Start/CLI.php mmap cache can't open phar://go-pear.phar/PEAR/Start.php There are 20 of these lines. After continuing through the script, it dies with this error:
2
2925
by: wannabe | last post by:
This is being installed on WindowsXP home edition. I am a complete novice at working with php and have just installed apache2_2, php5, mySQL5.0 and phpMyAdmin 2.10.1. After installing all 4 programs following the instructions from http://www.semtopia.com/?p=28 it tells you to create a file called testpear.php to test your pear install when working with MySQL and PHP. The file I was to create contains this information: <?php ...
3
6434
by: Rob Wilkerson | last post by:
Hey all - I'm bumping into an issue with my installation of the MDB2 package that I'm hoping someone else has seen. I'm trying to execute a query, but get an "unknown error" exception that I can't seem to track down (exact message is "MDB2 Error: unknown error"). I have an ObjectDAO class (which I'm creating via a factory) that extends an abstract DataAccessObject class. The database connection is created in the parent class'...
1
1535
by: slowpoke115 | last post by:
I have a simple login page with 2 fields (email and password), these details are then sent to another page which processes the inputs and sends them off to a PEAR server and awaits a response, it then comes back with one of 3 values: 5 values (NO_EMAIL, NO_PASSWORD, ACCOUNT_LOCKED, LOGIN_INVALID or a userID, a numerical value). What i really, REALLY want is all this on one page (my login page), instead of 2. So a user logs into a single page, if...
0
8265
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8196
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8705
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8637
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8504
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7193
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4092
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2625
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1511
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.