MySQL - related functions and concepts
get_magic_quotes_gpc() -- magic quotes are intended to prevent
you from inserting certain characters into MySQL databases (these are: ' " \ NUL)
addslashes() -- to be used (if the get_magic_quotes_gpc() returns false) to return a "safe" string.
removeslashes() -- reverses the string returned by addslashes to the
state of the original argument to addslashes().
To move a database from one server to another, you can
either use a tool such as PHP_MySQL_Admin to export the database
in various formats, or you can use the tool mysqldump, which
will give you a text file that contains SQL commands useful for
reinitializing the database. Once you have redirected the output
of mysqldump to a file (mysqladmin -u php -p > ~/web/mySchema.txt)
you can compress it using gzip (gzip ~/web/mySchema.txt).
Once you have this file compressed, it can be downloaded via HTTP or
transferred to another server via SSH and/or SFTP. (sftp me@my.com
sftp> put mySchema.txt.gz)
|
|