Enqueued Style Sheet Extras Fine-tuning your additional style sheets

The WP_Styles class in WordPress allows for a few extra bits of fine-tuning via the extra property, which is amended by calling add_data( $handle, $key, $value ) method on the global $wp_styles.

View what extras are available

HTTP Error Fix Can now upload large images

When uploading large images over an approximate size (~2500×2000) I was encountering the HTTP Error message when trying to crunch the image (which ultimately fails and doesn’t produce the smaller pre-defined image sizes).

After trying several solutions, the following appears to have solved it for my setup, once and for all – add this to your .htaccess file:

View the code

Style Sheet Header Improvements Tidy up your WordPress Theme Details

The Theme Review Guidelines are often updated as each new version of WordPress is released, and although these guidelines are for themes submitted to the WordPress theme repository, they are a good baseline to which all themes should strive to achieve.

If your theme was written a while ago, your site might not be following all of the current best practices. Here are a few simple alterations you can make to your style.css file.

View the suggested improvements

Install WordPress via SSH

  1. SSH into your server, then navigate to your domain’s web root:
    cd /var/www/vhosts/example.com/httpdocs
  2. Grab the latest WP install
    wget http://wordpress.org/latest.tar.gz
  3. Get the files out of the archive:
    tar xfz latest.tar.gz
  4. Navigate to the wordpress subfolder:
    cd wordpress
  5. Copy everything back up to the web root:
    cp -rpf * ../
  6. Navigate back up to web root:
    cd ..
  7. Remove the wordpress subfolder:
    rm -rf wordpress
  8. Remove the downloaded archive file:
    rm -f latest.tar.gz

How to Conditionally Add Style Sheets for IE in WordPress

Update: http://code.garyjones.co.uk/enqueued-style-sheet-extras/#ie

Over time, Internet Explorer (IE) is getting better at rendering web pages how we want them, but while IE7 and earlier versions still have a (fast-fading) grip, we sometimes still need to provide exclusive styles to make them render our sites in an acceptable way. That is where conditional style sheets are used.
View the code