Vagrantpress + composer

Unfortunately you can’t use Vagrantpress and Composer directly together easily. Half of Vagrantpress is the WordPress setup itself which isn’t compatible. If you still wanted to leverage the base work Vagrantpress has done with PHP, Apache, MySQL etc, you could fork it and modify their WP module found here: https://github.com/chad-thompson/vagrantpress/blob/master/puppet/modules/wordpress/manifests/init.pp It would still require a … Read more

Flatten media files in uploads directory via linux terminal eliminating thumbnails?

Warning: Please make a backup first, as this can do irreversable damage. Go to your uploads directory: cd /path/to/directory cp -r uploads uploads.backup Flatten the files in uploads directory: find * -type f -exec bash -c ‘file=${1#./}; echo mv “$file” “${file//\//_}”‘ _ ‘{}’ \; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 2017/12/some-image-150×150.jpg —> 2017_12_some-image-150×150.jpg 2017/12/some-image-360×240.jpg —> 2017_12_some-image-360×240.jpg 2017/12/some-image-720×900.jpg —> 2017_12_some-image-720×900.jpg 2017/12/some-image.jpg … Read more

WP Admin missing icons, numerous JavaScript errors, but only when SCRIPT_DEBUG is false

Do you load own javascripts into the admin? If i recall correctly, if SCRIPT_DEBUG is set to true, the javascripts are not concenated, but loaded seperately. So if a custom javascript doesn’t play well being concenated, this can lead to the whole concenated javascript being corrupt and not being run correctly. Try removing the added … Read more

enable SFTP via SSH keys in wordpress

For connection through ssh, you have to specify the ssh user using FTP_USER define( ‘FS_METHOD’, ‘ssh’ ); define( ‘FTP_BASE’, ‘/home/user/wordpress’ ); define( ‘FTP_PUBKEY’, ‘/home/user/.ssh/id_rsa.pub’ ); define( ‘FTP_PRIKEY’, ‘/home/user/.ssh/id_rsa’ ); define( ‘FTP_USER’, ‘user’ ); define( ‘FTP_HOST’, ‘localhost:22’ ); I think you also need to define FTP_BASE. You also need to enable ssh upgrade access. From the … Read more

Shortest way to install WP-CLI

Downloading the Phar file is the recommended installation method for most users. As you showed, it’s basically just one line. It can’t really get shorter than that. And the steps make sense: download the file, make it executable and move it to the right location. There are alternative ways to install WP-CLI though. For example, … Read more

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