Export database in phpmyadmin - php

I recently created an Ubuntu Virtual Machine in VirtualBox to create a new project.
So now I created my database in phpmyadmin and I wanted to export my database to keep the data.
The thing is that when I try to export it it throws an error that says that the database couldnt be exported because the origin file couldnt be read.
It may be a php configuration problem (php.ini)? or maybe I created the virtual machine on a wrong way?
Thank you in advance.

For security, if you want to save a database, do a dump on the server directly.
You can take a look to this link : https://www.digitalocean.com/community/tutorials/how-to-import-and-export-databases-in-mysql-or-mariadb
phpmyadmin is good to have something more visual for an human and manage some little changes. But it's not enough secure to be publish on internet. Becareful about that.

Related

Local Drupal site installation failure

I am trying to import a local drupal site from a git repository.
I am using Acquia Dev Desktop2.
I keep getting this error and I was hoping if anyone has experienced this before and has a solution:
Any help would be greatly appreciated.
It is a database issue. Are you importing a database? Check your settings.php file and ensure that they point to a valid database, then, if you don't need to have any data to start with I would suggest ensuring that the database is empty (no tables) and then do a site install via the UI or whatever.
If you are intending to import a database then it looks like the database you've got is corrupt or incomplete.

How do I set up a database on PhpStorm?

I am in the process of setting up my development environment and I just need to set up the MySQL Database. I have a .sql file and I'd like to import the information from that into a local database in PhpStorm.
I have the .sql file in my main project folder and I dragged it over to the Database Tool Window and it showed up as a DDL.
My question is: How do I turn that into an actual database that I can run off of localhost?
This is what I see
There is no database in PhpStorm. You need to set up a local server and THEN connect PhpStorm to that database.
If you are a beginner on Windows then you cannot go wrong with XAMPP.
PhpStorm can read the DDL but cannot store any data.
Hope that helps.

Running Wordpress repo locally through MAMP. Assets not being pulled in

Currently I am trying to run a Wordpress repo locally for development. I am not using MAMP pro even though I still have a 9 day trail. I figured since I'm going to be using the free version for now I might as well work with that. I have my Apache & MySQL server running along with the Document Root pointing to my Sites folder where my projectName repo sits. I'm still running off of the default port of Apache 8888.
After I start the servers, I open WebStart and import my DB into phpMyAdmin. Everything works perfectly fine and the copy of my db gets imported. I then make sure that my wp-config.php file has the appropriate settings to access this db. I then click on My Website. This pulls up the content of the website. However, it does not pull in any of the assets(imgs/js/css). I receive the following errors in the console:
Failed to load resource: net::ERR_EMPTY_RESPONSE http://projectName.dev/wp-content/uploads/2016/09/logo-footer-1.png
Failed to load resource: net::ERR_EMPTY_RESPONSE http://projectName.dev/wp-content/themes/projectName/images/circle.png
And so the list goes on and on for pretty much every asset the project could possibly have. Now configuration is NOT my strong suit, and at this point I am at a loss of what could possibly be happening. Awhile ago I did follow a tutorial on how to setup my files so that I can access them in the web browser by simply typing the name of the project with the domain .dev, example: projectName.dev. I started having issues with this after upgrading to OS Sierra and it no longer works. Could this possibly be the reason as to why it is looking for these assets in the projectName at the .dev domain?
I apologize if this does not make sense. I am willing to provide anyone with any information on this as I need as much help as possible because I still need to level up my configuration skills. Let me know if you have questions.
The images and other assets are referenced with an absolute filepath (i.e. the URL of the server on which you first set it up). This has to be changed in all database entries. There are tutorials for this on the net, but the most simple version is to open the sql file in an editor and search & replace the general URL part in the complete database.
Be sure to keep a backup of the file - that might not work on the first try...

From schema to SQL

I just started out with CakePHP and try to configure a plugin.
The plugin requires a table and contains a schema.php file that contains a class describing the table. From what I gather I have to run a command in my server CLI that will build a table according to this schema.
But my server doesn't seem to have CLI (it's cPanel, and my website is hosted by a good but cheap host). I tried to access the server using Putty, but the connection is aborted when I try.
However, I do have phpMyAdmin where I can run SQL commands. So if I can 'convert' my schema.php in the appropiate SQL commands, I can copy these manually and run them. Is there an easy way to do this?
(I know, the fasted solution is probably to just enter the table by hand. but that would be boring)
Thank you!!
Scipio

Joomla Database Problem

I am a beginner to Joomla, I have installed Joomla 1.5 in my server with Fantastico including sample data, also i have installed joomla in my local server. I Don't know how to upload this project from local to real server, when i completed my project , i have exported my database and import this Database in to real server after deleting all tables from real data base. But everyday this database data automatically changed to old sample data? I don't know how to fix this problem. Please any one help me!!!!!!!!
I've never used Fantastico to install Joomla, but:
To copy a Joomla installation from a server to another you'll need to:
Copy the content of your webroot (be careful about permissions)
Adjust the config parameters from the config.php or through the admin panel
Dump the database from the old website and import it into the new one.
My feeling is that you're trying to "install" Joomla again on the real server, and during the installation you're confirming the creation of the sample data (this will override the existing tables).
Are you sure you're using the right database name in your real server? Maybe you have two or more...

Categories