Unable to Edit or Rotate Images in WordPress

Have you ever experienced the following error in WordPress:

Could Not Load the Preview Image
Could not load the preview image. Please reload the page and try again.
Chances are you have WHM/cPanel and are running ModSecurity with the following rules enabled:

950120, 960015, 981243, 981044, 981049, 950901, 981245, 981243, 981257
If you have access to WHM yourself, you can disable the rules yourself.

  1. Log into WHM
  2. Navigate to Security Center
  3. Click on ModSecurity Tools
  4. Search for each of rules 950120, 960015, 981243, 981044, 981049, 950901, 981245, 981243, 981257
  5. Choose to Disable each rule
  6. Restart Apache after you disable each rule

Get Back the System Sleep Preferences in Mac OS X

I recently purchased a Mac Pro (late 2013) and discovered that the Energy Saver Pane is a little different; most notably, the Computer Sleep slider is missing. Here is how to get it back.

First, use the following terminal commands to determine the model and board ID of your computer:

sysctl hw.model | awk '{ print $2 }'
ioreg -l | awk -F\" '/board-id/ { print $4 }'

Second, navigate to the following folder:

cd /System/Library/Extensions/IOPlatformPluginFamily.kext/Contents/PlugIns/X86PlatformPlugin.kext/Contents/Resources/

Third, determine the .plist file that corresponds to the model and board ID of your computer; e.g., Mac-F60DEB81FF30ACF6.plist.

Fourth, modify the file that corresponds to the model and board ID of your computer:

sudo vi /System/Library/Extensions/IOPlatformPluginFamily.kext/Contents/PlugIns/X86PlatformPlugin.kext/Contents/Resources/Mac-UDID.plist

Fifth, change the following line:




Sixth, regenerate kext cache by “touching” the Extensions directory:

sudo touch /System/Library/Extensions

Finally, wait a minute just to make sure the system has enough time to finish regenerating the kext cache. Then, reboot your mac.

Alas, you will once again have the two-slider pane.

System Energy Dual Preferences

Make WordPress Print Pretty

Making your WordPress site print-friendly is probably not the first thing on your GTD list. However, the process is relatively straightforward. The simplest method is editing your existing header.php and style.css files.

First, look for the HTML declaration in your theme’s main file, usually header.php. Search for something like this:

<link rel="stylesheet" 
href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />

Change the last attribute to:

media="screen, print"

Second, it’s time to edit your theme’s CSS file, usually style.css. Add the following code to the bottom of the stylesheet:

@media print and (color) {
* {
     -webkit-print-color-adjust: exact;
     print-color-adjust: exact;

That’s it! If you have caching enabled, remember to empty your cache. Happy printing.

Hide SafeMonk Shortcut on Mac Desktop

SafeMonkI recently installed SafeMonk to encrypt my DropBox files. Unfortunately, SafeMonk adds an unnecessary shortcut to the desktop. Below is a nifty trick to hide that shortcut.

Open a terminal session, type “SetFile -a V”, and drag the SafeMonk shortcut onto the terminal window. You should observe an output along following lines:

# sudo SetFile -a V /Users/[username]/Dropbox/SafeMonk

Press enter and type in your password after the prompt. The above command “SetFile” sets the invisible extended attribute on the SafeMonk folder. You will next need to relaunch Finder for this setting to take effect. You can do this by entering “killall Finder” in your terminal session. Finally, you might want to put an alias (not a symlink) of the SafeMonk folder in your Dropbox folder.

How to Fix the UNDO command in Apple’s Mail.app when using Gmail

You may have noticed that the UNDO command in Apple’s Mail.app does not function as expected with Gmail IMAP. For example, when you delete a message and then press Command-Z, nothing happens. Fret no more because there is a workaround to correct this unexpected behavior.

The Workaround

  1. Go to your “Mail Settings” in Gmail.
  2. Click the “Forwarding and POP/IMAP” tab.
  3. Click “Auto-Expunge off – Wait for the client to update the server.”
  4. Click “Save Changes” at the bottom of the page.

Now you should be able to “Undo” your actions in Mail.

How To Downgrade from Mac OS X 10.6.7 to 10.6.6

Snow Leopard Install Screen

  1. While OS X is running, insert your OS X Snow Leopard Install DVD.
  2. Double click Install Mac OS X.
  3. Keep the DVD inside your computer while you wait for it to restart.
  4. Wait until the second phase of the installation procedure completes.
  5. You are now downgraded to OS X 10.6.2 (or something less than 10.6.6).
  6. Download and apply the OS X 10.6.6. combo update to bring you back to 10.6.6.