473,237 Members | 1,173 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,237 software developers and data experts.

Where is DB.php file located?

RC
I just downloaded, compiled and installed
PHP 5 in my Redhat Linux enterprise 3 update 4.

I try to connected to PostgreSQL database

I got error on line

<?php
require_once('DB.php');
....
?>
Warning: main(DB.php) [function.main]: failed to open stream: No such
file or directory in /var/www/html/hads/PHP/states.php on line 7

Fatal error: main() [function.require]: Failed opening required 'DB.php'
(include_path='.:/php/includes:/usr/local/lib/php') in
/var/www/html/hads/PHP/states.php on line 7

According to O'Reilly book Programming PHP
by Rasmus Lerdorf & Kevin Tatroe
The PEAR DB library is comes with PHP.
But I coun't find that file anywhere
in the system.

find / -name "DB.php" -print

This is the options I used below for config
'./configure' '--prefix=/usr/local' '--enable-calenda' '--enable-ftp'
'--with-apxs2=/usr/sbin/apxs' '--with-pgsql=/var/lib/pgsql'
'--with-libxml-dir=/usr/local/lib' '--with-xsl=/usr/local/lib'
'--enable-xslt'

Did I do something wrong? Please tell me how to
correct this.

Thank Q very much in advance!
Jul 17 '05 #1
2 14541
On Wed, 04 May 2005 16:04:42 -0400, RC <ra**********@nospam.noaa.gov> wrote:
I just downloaded, compiled and installed
PHP 5 in my Redhat Linux enterprise 3 update 4.

I try to connected to PostgreSQL database

I got error on line

<?php
require_once('DB.php');
...
?>
Warning: main(DB.php) [function.main]: failed to open stream: No such
file or directory in /var/www/html/hads/PHP/states.php on line 7

Fatal error: main() [function.require]: Failed opening required 'DB.php'
(include_path='.:/php/includes:/usr/local/lib/php') in
/var/www/html/hads/PHP/states.php on line 7

find / -name "DB.php" -print


pear config-show

... would give you the pear configuration - if it doesn't, then something's
wrong.

/usr/local/lib/php which is on your include_path according to the error
message would be consistent with where PEAR normally puts files.

My PHP 5.0.4 installation does NOT have the DB module installed, so it doesn't
come with PHP 5.0.4.

Try:

pear install DB

--
Andy Hassall / <an**@andyh.co.uk> / <http://www.andyh.co.uk>
<http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool
Jul 17 '05 #2
RC
Andy Hassall wrote:


pear config-show

My PHP 5.0.4 installation does NOT have the DB module installed, so it doesn't
come with PHP 5.0.4.

Try:

pear install DB


I have 5.0.4, too
Just issued the
pear install DB
It auto downloaded and installed
Great! Thanks a lot!
Jul 17 '05 #3

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

Similar topics

2
by: SillyChild | last post by:
Hi all, I'm trying to run PHP in my Apache on windows XP and so far it's not working. I have been looking at various installtion pages and all they talk about is php4apache2.dll. But where is...
3
by: Jim SUTTON | last post by:
Full blown VB6 has a global object called App which I can use to find the location in the file system of the exe I am running (App.Path). Is there a ready equivalent in VBA? Specifically, I am...
1
by: Tom | last post by:
How can you figure out exactly where in the classpath a class is located ? For example, assume that my computer has a class "com.MyCompany.MyClass" that is physically located in the jar-file...
7
by: Yongsub Eric Shin | last post by:
Hi. I'm just a beginner in ASP.Net. I started writing codes and I keep on getting this Runtime Error page, where it says "Description: An application error occurred on the server. The current...
5
by: feng | last post by:
Hi, We just converted our VB.Net Windows exe project from VS.Net 2002 to VS.Net 2003 and ran into a problem. the MyApp.exe.config file that we use for our customized configuration settings is...
0
by: Village Idiot | last post by:
First time SQL Server Management user here. I've finished a class assignment and I'm trying to find the folder/file where the database project is located (great how your teacher gives you an...
14
by: brett | last post by:
I'm running PHP5 on Windows Vista with mysql 5.2. I have a simple php file with <? $dbc = mysql_connect (); ?> When I run the file, I get this error: Fatal error: Call to undefined...
4
by: Rob | last post by:
The app.config in VB 2005 appears to be riddled with bugs.... From solution explorer I right click on the Project | Properties... then I use the grid to add the app settings... AND they are saved...
3
by: Scott M. | last post by:
If I add a setting to my project in the settings designer and mark it as a user setting, and then access and modify the setting via code, where is the updated setting stored so that it won't be...
7
by: cmrchs | last post by:
Hi, In Windows Vista: where does asp.net write its cookies? I use HttpCookie objCookie = new HttpCookie("nameCookie"); in Win2000 (and later) they used to be in C:\Documents and...
0
by: jianzs | last post by:
Introduction Cloud-native applications are conventionally identified as those designed and nurtured on cloud infrastructure. Such applications, rooted in cloud technologies, skillfully benefit from...
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
0
Git
by: egorbl4 | last post by:
Скачал я git, хотел начать настройку, а там вылезло вот это Что это? Что мне с этим делать? ...
1
by: davi5007 | last post by:
Hi, Basically, I am trying to automate a field named TraceabilityNo into a web page from an access form. I've got the serial held in the variable strSearchString. How can I get this into the...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...

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.