Blog Planet Wiki Why is this page pink?
Feed Feed It

New Keyboard

Friday, August 31, 2007 03:51 AM

New keyboard is wicked! It's super thin and more comfortable than my current Apple wireless keyboard is to work on. I can't wait for the wireless version of this

IMG_0124.JPG

IMG_0121.JPG

Speaking of keyboards I think it's time to invest in a couple of Kinesis keyboards.

Kinesis

iPhone Javascript Magic

Tuesday, August 28, 2007 11:38 PM

If you want a web page or a iPhone ready website to hide the "url-bar", just add the following to your onload event in your body html tag.setTimeout(scrollTo, 0, 0, 1)Here's the begin "body" tag as an example.

<body onload="setTimeout(scrollTo, 0, 0, 1)" />

iPhone Woes

Tuesday, August 28, 2007 02:53 AM

Last Friday night, when coming home from the bar I noticed that I couldn't touch the "home row" on my iPhone screen. I instantly thought, perhaps a reboot is in order. Did the reboot, no love! I was livid! I couldn't believe it. I know the rule and I broke it. The rule is: "Never buy anything Apple that is 1st generation." I'm going to modify this rule to "Never buy anything Apple that is 1st generation, ever!" I couldn't really use my phone to make any calls, it was essential to get this fixed. Of course being a loyal Apple customer I know exactly what to do. Get on the Apple Store website and schedule an appointment. The next day, I was in the Apple Store. I assumed I would be getting a brand new iPhone, and be on my way... wrong! I got a "loaner" iPhone and a $30 fee. I was assured that my repaired iPhone would be shipped back to me within 7 business days. What if this thing breaks again, what then? Tons of questions flooded my head. So I took pictures of the "loaner" iPhone, and it's AppleCare packaging.

IMG_0090.JPG

IMG_0098.JPG

IMG_0104.JPG

IMG_0111.JPG

Good Times!

Sunday, August 26, 2007 05:41 AM

Late nights at the office is too much fun with Apple's Photo Booth!

Photo 8

Renew Lease iPhone Bug

Thursday, August 23, 2007 11:06 PM

I found an awesome iPhone bug today.

IMG_0280

I was able to reproduce this bug on other iPhone's by assuming the following....

  • You are using a 802.11g access point.
  • You are using security, specifically WPA enabled using TKIP.
  • You are already connected to your access point.

To reproduce the bug follow the steps below...

  1. Goto Settings on the home screen.
  2. Select Wi-Fi
  3. Select the ">" for your connected Access Point.
  4. Goto BootP tab.
  5. Goto Static tab.
  6. Goto DHCP tab.
  7. Scroll to the bottom of the screen.
  8. Press the Renew Lease button.
  9. Confirm by pressing the Renew Lease button again from the popup.
  10. Repeat steps 8 and 9 to grow your buttons!


Bebo Offices, Cribs Style

Wednesday, August 22, 2007 07:39 AM

I found this video on Mashable.

Image Retargeting

Wednesday, August 22, 2007 06:46 AM

This is an amazing technology! Very hott!

Trek

Wednesday, August 22, 2007 12:51 AM

Guy Kawasaki visited the Trek corporate headquarters, I instantly thought of my ex-apartment mate Ben! Check out Guy's blog post here.

OSX hosts file issues

Sunday, August 05, 2007 08:17 PM

I've been doing some web development, and decided to use my MacBook Pro. I've never really used OSX for any kind of development. I usually use a Linux box when performing web development. Because I'm using Apache with virtual hosts. I was in a situation where I needed to remove my development entry for the virtual hosts from /etc/hosts. Removing the entry went without a hitch, but it was when I added the entry back into the hosts file that I encountered the problem. A google search yielded a few solutions none of which worked for me, but the command below worked perfectly!

sudo lookupd -flushcache

Measure

Sunday, August 05, 2007 05:22 PM

One accurate measurement is worth more than a thousand expert opinions.

Admiral Grace Hopper

Players

Thursday, August 02, 2007 11:30 AM

Python and FTP

Wednesday, August 01, 2007 08:36 AM

I decided to automate some file transferring I normally do the old fashioned way via FTP. I decided this would be a great job for python. I came up with the following code....

from ftplib import FTP
#You probably want to initialize the variables below....
FTP_ADDRESS = "..."
FTP_USERNAME = "..."
FTP_PASSWORD = "..."
REMOTE_DIRECTORY = "... "
REMOTE_FILE = "..."
VERSION = "..."
ftp = FTP(FTP_ADDRESS)
ftp.login(FTP_USERNAME, FTP_PASSWORD)
ftp.cwd(REMOTE_DIRECTORY)
renamed_file = "%s.%s" % (REMOTE_FILE, VERSION)
ftp.rename(REMOTE_FILE, renamed_file)
upload_file = open(REMOTE_FILE, "r")
command = "STOR %s" % (REMOTE_FILE)
ftp.storlines(command, upload_file)
upload_file.close()
ftp.quit()

File as a byte array in .NET

Wednesday, August 01, 2007 08:00 AM

So I had a situation where I found myself trying to load data from a file into a byte array so I can base64 encode the binary data to be passed along via something "web" based. I've never tried to do this before, because well almost everything I've ever encountered pertaining to data within files has been string based, so I typically parse on newlines. Below is my solution....

//Probably want to initialize the path variable prior to hitting this code block,
// and perform the proper exception handling.

using(FileStream stream = new FileStream(path, FileMode.Open, FileAccess.Read))
using (BinaryReader reader = new BinaryReader(stream))
{
	int number_of_bytes = (int) stream.Length;
	byte[] bytes = reader.ReadBytes(number_of_bytes);
	string encoded_data = Convert.ToBase64String(bytes);
	//Do something with the encoded_data.
}

Now of course the premise of my method above was to be able to load whatever is in the file into a byte array, my file had only a small amount of data in it (32 bytes to be exact), if you have a file on the order of kilobytes or greater I wouldn't advise this method, and would choose to process the data contained within the file in some kind of "chunked" fashion.

Game

Wednesday, August 01, 2007 07:58 AM

This is a great post about deciding which game to play.

Error Scale

Wednesday, August 01, 2007 04:55 AM

IMG_0194.JPG

Been having this mental tug-o-war going on in my head. I saw this piece of paper, which was a print out of what looked like a white board "Error Scale", it immediately put everything into perspective for me.