Dump GoDaddy Day

It’s here!  If you haven’t done it yet, this is the day to officially dump GoDaddy and move your domains and hosting to another, more anti-SOPA company.

Here is an article explaining how to move your domain name(s) to a new registrar.

Here is an awesome domain registrar to move your domains to. Use the coupon code SOPAsucks for a discount.

Wondering what this is all about? Read a little history on how GoDaddy managed to piss off the entire Internet.

VMware – RHEL / CentOS 6.2 – Network Issues

Howdy folks,

I just grabbed CentOS 6.2 (don’t know if it’s an issue in 6.0, 6.1), but an installation with the “Basic Server” within VMware Fusion 4.1.1 delivered no IP address etc. when leaving DHCP/NAT as the default.

Finding: Seems, either something is goofed in the dhclient or NetworkManager (now default for RHEL 6.x).

Fix: I brought the network interface up “ifup eth0”, then ran “dhclient eth0”, obtained an IP and ran “yum update -y”, after which (I noticed dhclient was in the updates), I was able to reboot and all worked well.

Not a big deal, as you could have just manually configured your network script, but maybe it will help someone. 🙂

Stop SOPA now

I’ve censored the following, in protest of a bill that gives any corporation and the US government the power to censor the internet–a bill that could pass THIS WEEK. To see the uncensored text, and to stop internet censorship, visit: http://americancensorship.org/posts/10253/uncensor

If ???? ??????, we ???? all ????? ?????? ???? ???? of ????? on a ??????? ?????. Go ???? ???? ?????????????? NOT to ???? for ????!

Uncensor This

WordPress Image Map Problems

I had many issues trying to get a good old-fashioned HTML image map to work in a WordPress page or post. It seemed that WordPress kept trying to add extra <map> tags around all my <area> tags. I couldn’t get it to stop!

After being led astray by such issues as wpautop() and the need to use various plugins, I finally figured out how to embed HTML image maps on my pages.

The trick is that you can’t use pretty, nicely formatted HTML because WordPress tries to automatically close tags and do various other things to your code when it detects new lines.

So instead of something nice like this:


You actually need to remove all the extra spacing and use something messy like this:

WordPress First & Last Navigation Items

I used to have a function which I would include in my WordPress functions.php file that would add a unique CSS class to the first and last menu items. This would be so you could assign them unique styles, such as padding or borders, for better looking menus in your themes.

With the advent of WordPress’s Menu system in version 3, I found it necessary to add some more functions for given situations: calling wp_list_pages(), wp_list_categories(), or wp_nav_menu().  So here they are:

First and Last Class for wp_list_pages();

// adds a unique class to the first and last items in the listfunction add_markup_pages($output) {$output= preg_replace('/page-item/', ' first-page-item page-item', $output, 1);$output=substr_replace($output, " last-page-item page-item", strripos($output, "page-item"), strlen("page-item"));return $output;}add_filter('wp_list_pages', 'add_markup_pages');

First and Last Class for wp_list_categories();

// adds a unique class to the first and last items in the listfunction add_markup_categories($output) {    $output= preg_replace('/cat-item/', ' first-cat-item cat-item', $output, 1);    $output=substr_replace($output, " last-cat-item cat-item", strripos($output, "cat-item"), strlen("cat-item"));    return $output;}add_filter('wp_list_categories', 'add_markup_categories');

First and Last Class for wp_nav_menu();

// adds a unique class to the first and last items in the listfunction add_first_and_last($output) {  $output = preg_replace('/class="menu-item/', 'class="first-menu-item menu-item', $output, 1);  $output = substr_replace($output, 'class="last-menu-item menu-item', strripos($output, 'class="menu-item'), strlen('class="menu-item'));  return $output;}add_filter('wp_nav_menu', 'add_first_and_last');

Disclaimer: I don’t remember where I picked up these functions from along the way, so I apologize if there is credit due to someone, somewhere.

Some Updates

Here are some updates of what has been happening around here lately.

First, I moved in with Rachael a few weeks ago, and last week they pulled a dead person out of the apartment downstairs. He or she had been there long enough to stink up the stairwells pretty bad. The EMS folks had to wear full-on biohazard suits. Check it out:

Dax and I went out to a farm in Clyde with Gary and his girls to check out a party where they were building a real, working trebuchet. Unfortunately, there were a series of setbacks, and they never got the thing working, but it still looked pretty cool.

Rachael and I attended the 16th Annual James Brown Oktoberfest, which was the first time for both of us, where I walked away with the Best Male Costume prize.  No one else was able to pull of the German pimp look as well as I. I owe it all to Rachael, of course, since she sewed my costume (and her own as well).

That’s all for now. Stay tuned!

clicky