How To Create a Grayscale PDF on Mac OS X

This morning I had to send over a PDF file to the printer and they wanted my color version in greyscale. To create a greyscale version of a PDF there are a few steps you need to follow:

  1. Go to the File menu and click “Print”. Once you are there – click on the PDF button (see screenshot) and select “Open PDF in Preview”
  2. Within Preview (the application) go to the File menu and select “Save…”. When the dialog box opens, you will see an option called “Quartz Filter”. In that drop down menu, choose “Gray Tone”.
  3. Save the PDF and then you can open it and see your new gray scale PDF

You also have the option in the “Quartz Filter” to save it as a black and white PDF, adjust lightness, etc.

WordPress Wednesdays: Jappler Category/Tag Feeds

Perhaps you come to this site because you personally know me or like some of the WordPress hints I like, or like my CSS posts, or just like my personal rants (which seem to happen less…hmm I need to get on that!).

If you are only interested in some of my posts but not others, you can easily subscribe to just certain “subjects” very easily.

For example, lately I have been posting on a certain subject each day. (WordPress Wednesdays, etc). If you are only interested in reading those posts, subscribe to this RSS feed: Perhaps you only want to read about things I post in the “Serenity Now” category. You can subscribe to Do you see what I am doing? This logic will work on any tag or category. Find the tag URL (click on a tag) or find the category URL (click on a category in the sidebar) and then add “/feed” to the end of the URL – and there you go. A custom filtered feed.

Just another way WordPress makes it easy to interact with content!

PHP 4 or PHP 5? You Pick the Flavor

I recently ran into a situation where there were two versions of PHP on a server and I needed to make sure PHP 5 was being used. To pick the version – all you need to do is add the following into your .htaccess file (assuming you do not have access to your httpd config):

For PHP 5:
AddType application/x-httpd-php5 .php

For PHP 4:
AddType application/x-httpd-php4 .php

It does not get much more easier than that!

How to Find Geographical Coordinates

Ever need to find your location using latitude and longitude? Do a search for your destination using Google Maps and then when your destination is in the center of the map – type:


into the browser address bar (no http or www) and your coordinates will appear.

Quick CSS for WordPress Images

If you install WordPress and use the media uploader to manage your images in your posts – you can easily style your images quickly by adding the following code to your theme’s stylesheet.

img.alignright, img.aligncenter, img.alignleft {padding:4px;background:#efefef;border-color: #aaa #ccc #ddd #bbb;border-style: solid;border-width: 1px;}
img.alignright {float:right;margin-left:5px;}
img.alignleft, img.alignnone {float:left;margin-right:5px;}
img.aligncenter {display: block;margin-left: auto;margin-right: auto;}

This code will set up your images to float appropriately, as well as give a nice border as seen below.

Christmas in DC

Note* This information is now updated: Updated CSS

Find and Replace With phpMyAdmin (or using SQL)

Ever need to find and replace something in your WordPress database? (perhaps you changed domain names and have the old domain name or folder structure hard coded into some of your posts) You can easily update your database by using phpMyAdmin or by using the following code in any SQL interface:

UPDATE wp_posts SET post_content = replace(post_content,"",""); 

The first part of the command says “update the database table wp_posts” (where your content is stored). The later part of the command says “use the field “post_content” (where all your actual post content is stored” and then find “” and replace it with “”. You can find anything (not limited to domain name) and replace it with anything as well. This is a great time saver!

Undelete Something With SVN

Ever delete something with svn (svn del) and then realize you needed it again? You can get it back by using: svn copy -r HEAD filenameyoudeleted.extension filenameyoudeleted.extension

  • svn copy is the command to get a working copy back
  • -r is short for revision. I used HEAD which will give you the latest in repository. You can specify a revision number, revision right before you committed, etc (check out svn help copy)
  • filename is what you deleted, then where it goes. I usually do something like this within the folder the file was located so you do not see any paths, but if your file was in /www/files/ you would need to specify the file path to /www/files/filnameyoudeleted.extension /www/files/filnameyoudeleted.extension

Working with SVN is a lifesaver – and this tip is gold.

Switch Repositories (SVN)

In order to take a look at WordPress 2.5 before it was released, I used subversion to check out the latest code available using the instructions given on the WordPress site. Once WordPress 2.5 was released, I wanted to keep my sites using 2.5 and not the bleeding edge releases (2.6) so I needed to easily switch repositories from to
I had never had to switch repositories, so it took some reading to figure it out. For future reference, the following command works when used in the directory you have the checked out files in: “svn switch .” For my example, I ran the command: “svn switch .”

How to Get Stuff Done

The last few weeks I have been extremely busy and on top of that I have been dealing with a sick child and also being sick myself. There is no time to be wasted so efficient use of the time I had was crucial. I feel that since owning my own business, I have had to work very hard to make the most of my time and have a few tips:

  • Focus on 1-3 big tasks per day. Any more tasks than 3 will most likely cause you to spend too much time switching gears. I have begun making a list (yes – let the comments start pouring in as I was anti-list for a long time) of these items and then crossing each item off as I finish. This is surprisingly very rewarding.
  • Limit how often you check email. (See a post I wrote on this in the past)
  • Start the day with an easy task. It sometimes takes more time to get going mentally in the AM so starting with an easy task quickly builds confidence for other tasks later
  • Take time every hour to take a small break to keep your mind fresh
  • If you are having a problem with something you are working on – move on and come back to it later. Sometimes I can easily get lost in a problem and stop thinking about it rationally but by stepping away and coming back to it – I can often solve the problem quicker than if I would have stayed with it.
  • Set a stopping point or time and stick with it. Feel good knowing you have put in 6-8 hours of work a day and realize that there will be things to do tomorrow and not everything needs to get done today. By setting limits, you will feel much more refreshed the next day and your spouse/family will be happier as well.