« September 2007 | Main | November 2007 »

Dreamhost Decennial

October 31, 2007

They’re is doing it again! To celebrate their 10 year anniversary, Dreamhost set up a coupon code to save $110.10 off their standard $119.40 yearly rate, which gets you a full year of hosting for less than ten bucks.

I first signed up with them back in July of 2005 when they were running a similar deal, and I am more than satisfied with the service I’ve received since then. While they have had a few problems over the last several years, you can’t find a better bargain for the price. When a deal like this comes along though, it gives the old “you get what you pay for” idiom whole new meaning.

Dreamhost used to have a set of 4 tiered plans for different levels of hosting, but now they just have one massive standard plan which includes:

  • 500GB of Disk Space (Increasing weekly by 2GB)
  • 5TB of Bandwidth (Increasing weekly by 40GB)
  • 1 Free Domain Registration
  • Ability to host unlimited domains/subdomains
  • Unlimited Emails, MySQL Databases, and FTP/Shell Users.
  • One-Click Installer for: WordPress, phpBB, ZenCart, Joomla, and more.
  • Ruby on Rails support
  • …and a whole lot more

Even if you are happy with your current hosting plan and have no plans of migrating to a new host, the free domain registration alone makes this deal worthwhile.

  1. Go to Dreamhost and click on the lemony, web 2.0 “Sign Up NOW!” starburst
  2. Select “Pay Yearly @ $9.95/mo: 9% off + no setup = $119.40
  3. Choose your domain name and enter your personal info
  4. Enter “101010” in the Promo Code box
  5. Checkout for only $9.30!
  6. Enjoy!

Unreal VMWare

October 10, 2007

Even though I don’t consider myself a “gamer”, I do like the occasional console or PC game now and then. I really enjoy first person shooters for the simple fact that I can jump into an online game, or gather some friends together and just frag the heck outta some people. I don’t have the patience for long adventure games or those that require learning some new move, skill, or spell at every turn. I just want to turn on the game, have some fun, and turn it off when I start to suck get bored.

For that reason, I keep going back to the old classic Unreal Tournament. If I could have gotten credit for the amount of hours I played that game and the original Halo in college, I could have gotten degrees in each. While Halo has gotten better and better with age, Unreal (in my opinion) hasn’t. I still enjoy playing the 1999 Game of the Year edition of Unreal Tournament more than any of it’s descendants.

At some point last week I decided I wanted to play Unreal during my lunch break here at work. Even though I’m on an Intel iMac, I knew there was a Mac port that worked on my G5 iMac at home. Unfortunately “Unreal Tournament X” (as it’s called) isn’t native to and doesn’t work with the Intel Macs, so my only other option was to run it on Windows via VMWare Fusion. I didn’t have high expectations when I brought in my Unreal Disc from home today, but to my surprise it worked right off the bat. The only problem was the mouse. It worked fine in the preferences window, but was so finicky during gameplay that I couldn’t get my eyes off the floor - literally. As you can imagine, this wouldn’t do.

Fortunately, Google revealed that French blogger Arnaud Boudou had the answer:

As written above, I got issues with mouse. in fact, the issue comes from “VMware Toolbox” and VMware’s mouse driver. this tool, with mouse driver, allow you to have a transparent mouse use between VMware and MacOS X. If you uninstall VMware Toolbox and mouse driver, you won’t encounter mouse issues with games anymore.

Sure enough, if you go into the Control Panel on your VMWare-booted install of Windows, you’ll see that the mouse driver is in fact a VMWare branded driver. To change this, simply open up the Mouse properties from the Control Panel, click the Hardware tab, select the driver, click the properties button, in the Properties window select the Driver tab and click the Update Driver button. In the wizard, manually select the PS/2 Compatible mouse driver and you should be good to go. The only downside that I’ve found is the mouse is a little slower (even with sensitivity turned all the way up) than I prefer.

Unreal Tournament being played in VMWare Fusion Windows

For some reason, the game will not run full-screen, even within the VMWare window, but it’s still very playable. As you can see, I even jumped into a quick internet game. Disregard the -4 spread, I was trying to take screenshots. ;) Anyway, it’s good to have UT back again and I’m looking forward to dusting off my Flak Cannon, Pulse Gun, and Rocket Launcher during future lunch breaks. Happy Fragging!

Active States on the Cheap

October 02, 2007

Whenever I create a navigation block for a website, I make sure it falls within a universal include file. This ensures that if I need to add a page or change the site navigation in any way, I just need to edit one file. Whether I’m working on a PHP or .NET project, these includes get processed server-side, allowing me to add a bit of code to set active states on the nav items. On jasongraphix.com for instance, I’m parsing the $_SERVER['REQUEST_URI']; and using the first “folder” to determine which list item to add an active id to. On .NET projects, I’ll usually pass a sectionname and pagename variable along with the include request and use that to choose the active section/page. Unless you’re running a completely database driven site, this is standard industry practice. Occasionally though, I have to add subnavigation to pages on older websites where site-wide include files do not exist, or where server-side coding isn’t an option. In these situations, I still want to get the navigation I’m working on into an include as it doesn’t take that much longer and will save me future work if the client decides to rearrange/rename any of the new pages.

Even on static html sites, you can usually use the good ole’ server-side include syntax to add a repeated block of code to multiple pages:

<!--#include FILE="subnav-section.inc" -->

Now let’s say you have a nav list in there like this:

<ul class="subnav">
    <li><a href="1.html">Chocolate</a></li>
    <li><a href="2.html">Hazelnut</a></li>
    <li><a href="3.html">Coffee</a></li>
    <li><a href="4.html">Cake</a></li>
</ul>

Hopefully, you don’t give your pages vague names like 1.html, I’m just tossing those in there for brevity. Anyway, let’s say you want to change the background and text color to indicate which page you’re on - yea, I know…an active state, I was just explaining for those who might not know.

One cheap and dirty way I’ve found to do this is to add a wrapper div or even the <ul> itself around the include call with an added class that is specific to the page you’re on. Then, you can add the same class to the link and use the combination to set the active state.

To demonstrate, if you’re on the Coffee page (and who isn’t), your include call might look like:

<ul class="subnav coffee">
<!--#include FILE="subnav-tasty.inc" -->
</ul>

Inside that include, you’d have:

<li><a href="1.html" class="chocolate">Chocolate</a></li>
<li><a href="2.html" class="hazelnut">Hazelnut</a></li>
<li><a href="3.html" class="coffee">Coffee</a></li>
<li><a href="4.html" class="cake">Cake</a></li>

Then, within your css, you would add something like this:

.chocolate li a.chocolate,
.hazelnut li a.hazelnut,
.coffee li a.coffee,
.cake li a.cake{
   background:#000;
   color:#fff;
}

And viola, if you’re on the coffee page, the coffee nav item now has white text on a black background. Easy peasy.