473,624 Members | 2,642 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

apache2+mysql+p hp4

Hello,
I'm trying to do some database work on an rh9 box. I installed httpd2,
mysq, mysql-server, and php4. I'm having difficulties connecting to a
database via a web page. I'm not sure if i missed something during the
install of the rpms or if i have a problem sql wise, and am hoping someone
can help.
When i installed mysql i ran:
mysql_install_d b
then set a password for the root user. I then logged in as the root user and
ran a grant command for a database i'll call example:

GRANT ALL PRIVILEGES ON example.* TO
DataBaseUser@lo calhost
IDENTIFIED BY 'password';

this returned no errors. Again, from the mysql commandline i can log in as
this user, and use the database. I can query it, and add/delete information
from it. My problem comes when i try to access the database via a web page,
both httpd and mysql are on the same box, and i get an access denied
message. Here's my connect string:

$connection = mysql_connect(" localhost","Dat abaseUser","pas sword");
mysql_select_db ("example", $connection);

and when i load the page i get the can not connect, access denied.
Suggestions welcome.
Thanks.
Dave.
Jul 19 '05 #1
0 1180

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

Similar topics

0
2191
by: Aldo Polli | last post by:
Hi, I have this error when I start apache2 with php4 Syntax error on line 233 of /mypath/apache2/conf/httpd.conf: Cannot load /mypath/apache2/modules/libphp4.so into server: dynamic linker: /mypath/apache2/bin/httpd: relocation error: symbol not found: ap_pass_brigade; referenced from: /mypath/apache2/modules/libphp4.so I compile apache 2.0.46 with
1
2246
by: Chris Haynes | last post by:
Hello all, I am attempting to install Apache 2.0.47 and php4.3.3 on slackware8.1. I am pretty new to linux and this is something of a learning experience and so I was anticipating a few problems along the way. Now I have pretty much followed the instructions at lamps.efactory.de/e-lamps-2-0.shtml word for word, but when i try to access a simple php file (<?php phpinfo(); ?>) in lynx it just shows me the source code (i.e. <?php phpinfo();...
5
2793
by: Ad Astra | last post by:
I am completely new to PHP and am finding installation the most difficult part to understand and implement. Could someone please review the rather long missive below and assist me? I have provided it in as clear a fashion as possible. COMPONENTS * Windows XP (Home) * Apache2 server (successfully installed; located as
3
6600
by: Armin Irger | last post by:
Hi, i'am running a debian sarge with the delivered apache2 mysql and php4. The file "mitarbeiter_eingabe.php" gets the data over a html <FORM> and send it to "mysql_mitarbeiter_daten_hinzufuegen.php" to write it in an mysql database. These already worked on php3 and mysql-3 and now on php4 and mysql4 it doesn't work. I can't found any changes between php3 and php4, mysql3 and mysql4 that explained the fact that only empty spaces are...
1
2060
by: Matthew Crouch | last post by:
I *always* have trouble getting LAMP up on a new distribution I'm trying out -- this is the chief reason for a bad case of upgrade-o-phobia that i have. This week it's Debian (Ubuntu). I successfully apt-getted apache2, mysql, and php4, but the latter did not include the mysql extension. Have been looking around for a place to download this so I can just plug it in and I thought I'd ask here if anyone knew of such a place. Right now...
0
1115
by: dave | last post by:
Hello, I'm trying to do some database work on an rh9 box. I installed httpd2, mysq, mysql-server, and php4. I'm having difficulties connecting to a database via a web page. I'm not sure if i missed something during the install of the rpms or if i have a problem sql wise, and am hoping someone can help. When i installed mysql i ran: mysql_install_db then set a password for the root user. I then logged in as the root user and ran a grant...
4
1796
by: Andy Baxter | last post by:
hello, I'm using the php4-mysql module with php4 under debian linux (sarge). I have a script, schedule.php, which runs fine when I invoke it from the command line, but fails with the error: Fatal error: Call to undefined function: mysql_connect() in /local/rivulet/interface/db.php on line 4 when I try to invoke it as a web page (using apache2). As far as I know,
8
2005
by: Daz | last post by:
Hi everyone. I was faced with the choice of whether my problem is indeed a PHP problem or a MySQL. I have decided it's a PHP problem as I don't experience the same problem when I execute the same query at the CLI. I am having trouble executing a large query through my PHP script. It takes about 7-11 seconds on average to execute, whereas the same query only takes 0.01 seconds to execute through the CLI.
1
4799
by: Randell D. | last post by:
Folks, I consider myself well versed with Apache 1.3 and PHP4 - I found drupal and wanted to try it out - I had problems getting it working with Apache2/PHP5/MySQL5 so I downgraded... Note: I did have Apache2/ PHP5 working... I confirmed this via phpinfo output... But now that I removed my original directory containing Apache/PHP, and recompiled from scratch, I get everything to startup and static html is displayd, but phpinfo produces...
0
8246
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
8179
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
7174
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...
1
6112
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
5570
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
4084
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...
0
4184
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2612
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
1489
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.