Testing Server database
Moderator: General Moderators
Testing Server database
I am using dreamweaver with a testing site and also to deploy my site once I am happy with any updates.
I have php & mysql installed on my localhost server and I was wondering if it is possible to be able to add a database that I can test on my localhost server and then upload to my www server without having to change any code.
I guess this will require the php script to determine if it is on the localhost or on the www host and I would have to have the same directory path on my local machine mimicking the path to the database on the www host.
Sorry if this isn't making any sense. My goal is to be able to set up an exact working duplicate of my site (database and all) on my local machine so I can test it and then deploy it to the www.
Do I need to contact my host provider to find out where they store my databases?
Brad.
I have php & mysql installed on my localhost server and I was wondering if it is possible to be able to add a database that I can test on my localhost server and then upload to my www server without having to change any code.
I guess this will require the php script to determine if it is on the localhost or on the www host and I would have to have the same directory path on my local machine mimicking the path to the database on the www host.
Sorry if this isn't making any sense. My goal is to be able to set up an exact working duplicate of my site (database and all) on my local machine so I can test it and then deploy it to the www.
Do I need to contact my host provider to find out where they store my databases?
Brad.
First set up the db on the remote server, then mimick everything on your localhost.bradles wrote:So do I need to add a MySQL database setting it up through my cpanel and then mimick everything on my testing server? Or can I set up the database and everything on my local machine and then just upload it?
Brad.
Does that mean I can edit the database on my local machine? Or do I have to test my site, upload php, go into cpanel and edit database manually. That would seem like double handling.patrikG wrote:First set up the db on the remote server, then mimick everything on your localhost.
Brad
[EDIT] I just got an email back from tech support saying:
Not sure what I do now.Well although the path to the databases is /x/y/z/databasename you do not have explict access to the above path. Using the phpmyadmin from your mysql feature, you can manage the mysql database and upload your database.
-
Breckenridge
- Forum Commoner
- Posts: 62
- Joined: Thu Sep 09, 2004 11:10 pm
- Location: Breckenridge, Colorado
Yes you can edit databases on your own machine and this is how you do it:
1. on your server set an sql user called remotedbuser or anyname you want with your network ip as the host UNDER THE users TABLE.
2. allow the user your created permissions to your database in the db table.
3. when you connect to your server use the ip of your server vs your server name
code and change/update your databases as you please from code running on your local computer.
need more help private message me
1. on your server set an sql user called remotedbuser or anyname you want with your network ip as the host UNDER THE users TABLE.
2. allow the user your created permissions to your database in the db table.
3. when you connect to your server use the ip of your server vs your server name
code and change/update your databases as you please from code running on your local computer.
need more help private message me
How do you go about it feyd?
In particular, after tech support sent me the following information:
Brad
In particular, after tech support sent me the following information:
I'm stuck on how to set this up. They have told me the folder path is /x/y/z/databasename but those folders are not in my www path.Well although the path to the databases is /x/y/z/databasename you do not have explict access to the above path. Using the phpmyadmin from your mysql feature, you can manage the mysql database and upload your database.
Brad
- John Cartwright
- Site Admin
- Posts: 11470
- Joined: Tue Dec 23, 2003 2:10 am
- Location: Toronto
- Contact:
Feyd, can you then add tables etc to the database on your local server and update the changes to the db on the www? Or do you have to manually go into the www db and add the new tables and any edits etc?feyd wrote:when I want to bring over the stuff.. I make it on the server, export the data, and import it into my local server.
Brad