473,666 Members | 2,073 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

PEAR DB

Hey All,

When I have
DB.php (PEAR)
in the root directory of my project it works ok using
require "DB.php";

When I put it in a seperate folder and call it using
require "classes/DB.php";

i get the following errors:

Warning: Problem with method call - please report this bug in /
home/..../DB.php on line 520
Warning: Problem with method call - please report this bug in /
home/..../DB.php on line 543

Apr 12 '07 #1
4 2739
andy wrote:
Warning: Problem with method call - please report this bug in /
home/..../DB.php on line 520
Warning: Problem with method call - please report this bug in /
home/..../DB.php on line 543
What is on those lines?

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact
Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux

* = I'm getting there!
Apr 13 '07 #2
This is the PEAR DB.php

520: $dsninfo = DB::parseDSN($d sn);
....
540: $tmp = PEAR::raiseErro r(null, DB_ERROR_NOT_FO UND, null, null,
541: "Unable to include the DB/{$type}.php"
542: . " file for '$dsn'",
543: 'DB_Error', true);
On 13 Apr, 10:02, Toby A Inkster <usenet200...@t obyinkster.co.u k>
wrote:
andy wrote:
Warning: Problem with method call - please report this bug in /
home/..../DB.php on line 520
Warning: Problem with method call - please report this bug in /
home/..../DB.php on line 543

What is on those lines?

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~http://tobyinkster.co.uk/contact
Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux

* = I'm getting there!

Apr 16 '07 #3
andy wrote:
520: $dsninfo = DB::parseDSN($d sn);
...
540: $tmp = PEAR::raiseErro r(null, DB_ERROR_NOT_FO UND, null, null,
541: "Unable to include the DB/{$type}.php"
542: . " file for '$dsn'",
543: 'DB_Error', true);
Both of those look fairly innocuous, so I'm guessing the error is
elsewhere.

Firstly, do you have you made sure that PEAR DB supports your version of
PHP?

Secondly, try turning on all error reporting (error_reportin g(E_ALL)) and
see if any more interesting errors show up -- I'm guessing there might be
something about being unable to include a particular file.

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact
Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux

* = I'm getting there!
Apr 16 '07 #4
Yes it supports the database, I have two version of the php script i
am writing, same server, same account etc.

The only differance is the way DB.php is stored.

one is in the root directory
include "DB.php";

one is in a sub directory

include "pear/DB.php";

On 16 Apr, 08:28, Toby A Inkster <usenet200...@t obyinkster.co.u k>
wrote:
andy wrote:
520: $dsninfo = DB::parseDSN($d sn);
...
540: $tmp = PEAR::raiseErro r(null, DB_ERROR_NOT_FO UND, null, null,
541: "Unable to include the DB/{$type}.php"
542: . " file for '$dsn'",
543: 'DB_Error', true);

Both of those look fairly innocuous, so I'm guessing the error is
elsewhere.

Firstly, do you have you made sure that PEAR DB supports your version of
PHP?

Secondly, try turning on all error reporting (error_reportin g(E_ALL)) and
see if any more interesting errors show up -- I'm guessing there might be
something about being unable to include a particular file.

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~http://tobyinkster.co.uk/contact
Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux

* = I'm getting there!

Apr 16 '07 #5

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

Similar topics

3
3545
by: Sandro Dentella | last post by:
I need to use a class to handle mbox files that uses PEAR. Since I'm using Debian (both woody and, I simply apt-get(ed) php4-pear but I can't use it becouse I get the error: Warning: dl(): Unable to load dynamic library '/usr/lib/php4/20020429/PEAR.so'- /usr/lib/php4/20020429/PEAR.so: cannot open shared object file: No such file or directory in /home/sandro/src/php/mbox/PEAR.php on line 11 in fact PEAR.so is not there, nor it seems...
3
7237
by: junkmail | last post by:
on a win 2k server apparantly it is saying i dont have it. or it cant find it. im using mySQL 4.1 php 4.3.x apache 3.0.53 im new to php and am doing some tutorials, but when i run the sripts it tells mea it can not run pear/soap, because it can not be found.the book im learning form does not tell me how to install or configure this extension. so now im looking for help.
1
2044
by: DJ Majestik | last post by:
OK, I am new to the whole PEAR/Smarty templating thing. I am trying to setup my directory structure correctly. If someone could weigh in and see if I have this setup "right", I would appreciate it. Directory structure: pear/ db/ db/ DB/ doc/
3
2200
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"
2
5776
by: Alan Prescott | last post by:
I'm running SuSE Linux 9.3, fully up to date running # pear install db responds with ... downloading DB-1.7.6.tgz ... Starting to download DB-1.7.6.tgz (124,807 bytes) .............................done: 124,807 bytes requires package `PEAR' >= 1.0b1 DB: Dependencies failed Googling around this ng I found someone with a similar problem who solved it
5
14229
by: Jim Michaels | last post by:
I downloaded a PEAR module, but it came with this XML file and a PHP file. I figure I just include the PHP file somehow, but what do I do with the XML file?
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...
1
2223
by: IchBin | last post by:
I am new to PHP and I am running on Windoze XP SP 2. Just noticed that the PEAR installed dir structure I have (to DB subdir) is : C:\php5.2\PEAR\pear\DB My registry vars are: "PHP_PEAR_SYSCONF_DIR"="C:\\php5.2\\PEAR" "PHP_PEAR_INSTALL_DIR"="C:\\php5.2\\PEAR\\pear" "PHP_PEAR_DOC_DIR"="C:\\php5.2\\PEAR\\pear\\docs" "PHP_PEAR_BIN_DIR"="C:\\php5.2\\PEAR" "PHP_PEAR_DATA_DIR"="C:\\php5.2\\PEAR\\pear\\data"
1
7834
by: CSTechie | last post by:
I've been battling to install PEAR on Windows XP now for too long. I am not sure what I need to do. When I run go-pear.php from the command line, I get the error message as shown at the end. I included everything in case there is something there that's helpful. I'm trying to install PEAR so that I can use PHPUnit. Thanks for the help!!!!
1
13663
by: IchBin | last post by:
I remember having problems with pear when I first installed it but got it running some time ago. This is on a windoze XP SP OS. I did not think it was correct because it pointed to "C\php\pear\PEAR". I writing a pear front-end GUI and I want to have it installed correctly. It seemed to have some duplication of directories between the lower and upper cased pear dir names. Should there be a "php\pear\PEAR" subdirectory? I thought it should...
0
8448
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
8356
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,...
1
8552
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8640
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...
1
6198
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5666
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4198
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
2773
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
2011
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.