Migrate localhost to server

You can use the WP CLI too to rename your site’s hostname safely and effectively. There’s a chance that your layout is being messed up because naively replacing the domain name with a simple string replace, e.g. perl -pi -e ‘s/oldhost/newhost/g’ backup.sql, will not take into account things like serialized data. Try this on your … Read more

How to set path with WP_Filesystem and ftp base / chroot

After changing FTP_BASE in my wp-config i found the update function of WP broken. Then i realize the update function work the same way and don’t need any additional settings. In wp-admin/includes/update-core.php i found the usage of $wp_filesystem->wp_content_dir(). This solves my problem too. On http://xref.wordpress.org/branches/3.8/WordPress/Filesystem/WP_Filesystem_Base.html you will find a list of possible useful functions: string … Read more

WP Config for FTP credentials

define(‘FS_METHOD’, ‘ftpext’); define(‘FTP_BASE’, ‘/path/to/wordpress/’); define(‘FTP_CONTENT_DIR’, ‘/path/to/wordpress/wp-content/’); define(‘FTP_PLUGIN_DIR ‘, ‘/path/to/wordpress/wp-content/plugins/’); define(‘FTP_PUBKEY’, ‘/home/username/.ssh/id_rsa.pub’); define(‘FTP_PRIKEY’, ‘/home/username/.ssh/id_rsa’); define(‘FTP_USER’, ‘username’); define(‘FTP_PASS’, ‘password’); define(‘FTP_HOST’, ‘ftp.example.org’); define(‘FTP_SSL’, false); http://digwp.com/2010/11/ftp-in-wpconfig/

Plugin to edit htaccess file

Here are a couple of options: WP htaccess Control – will let you manually edit your .htaccess file All-in-one htaccess Plugin – will let you dynamically create an .htaccess file based on which modules/features you want set up When all else fails, turn to Google …

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)