PDA

View Full Version : Cannot Access database online


kuasadmin
05-18-2009, 05:49 AM
I am using DWCS3, with Xampp 1.7.1.
I have managed to set it up locally and everything is working fine with localhost. I have managed to also FTP my files onto my website online and ran it without any problems at all except for the Database connection.
On the localhost I managed to connect to my database, with my search and result.php query but when I sent my files online and ran the same thing it couldn't find my database. I have already dumped my database sql and imported it online, I can see it on MyPhpAdmin.
What else do I need to do? What is my testing server supposed to be, not sure if this is supposed to be linking locally or on FTP?
Any help is appreciated.

edbr
05-18-2009, 06:05 AM
your testing server is what it is named for you test before putting live your database on your online server will have different connection settings password and username. Have you changed this connection correctly?

kuasadmin
05-18-2009, 11:37 PM
Okay I am not sure what to change it to? Okay if my website is
e.g http://www.bestas.com and my root folder is in public_html folder.
When I am working on my dreamweaver I set to localhost as follows;

Local Info:
local root folder - c:\xampp\htdocs\web1\
images folder - c:\xampp\htdocs\web1\images\
Links relative to Document (selected)
HTTP Add: http://localhost/

Remote Info:
Access - FTP
FTP Host: ftp.bestas.com
host Dir: public_html/
login: mylogin
password: mypass
also used passive FTP
tested and it worked

Testing Server:
Server Mode - PHP MYSQL
Access: Local/network
testing server folder: c:\xampp\htdocs\web1\
URL Prefix: http://localhost/kuaonline

All the above works fine when I am running locally, but how do I set or where do I need to change to have it working online?
I have my cpanel password, and also my MyPhpAdmin password. Where do I need to use this on dreamweaver?
As I said I uploaded all my files online and tried running the search and results.php but it didn't work?
Appreciate your help..

kuasadmin
05-18-2009, 11:39 PM
Oh forgot to add MySql Connection locally:
connection name: dbconnect
MYSQL Server: Localhost
username - admin
password - pass
database - test
This was connected locally not online though.

edbr
05-19-2009, 02:18 AM
right theres you problem then.
your local server will be different.
you must add a user to your online database with a pass word and give that user permissions. There will be a msql manager on your server to allow you to do this, its not difficult.
then you must change your settings to this connection , you will be given add details when you add a user.

probably something like
MYSQL Server:localhost
username - server_username
password - password
database - server_test
you own details of course

kuasadmin
05-19-2009, 03:12 AM
I got it!!! Thanks alot.. It was just a mix up with my username database name and the MySQL Server localhost name.
Ur the Greatest!!