iPhone quick tips
When navigating the web, you can zoom in on the webpage by double tapping the screen. To zoom back out, double tap again.
When navigating the web, you can zoom in on the webpage by double tapping the screen. To zoom back out, double tap again.
Just got an iPhone and have been trying to figure out how to play games on it. It took me a couple days, but I finally realized that you can’t download games to the phone like you can on most other cell phones. Instead, you have to go to the iTunes website and play these little web apps games directly from the Internet (assuming you can find the games, that is. Trying to navigate through the iTunes website on the iPhone screen is like embarking on a Grail Quest–you really have to want to find the games sections to endure all the midget print and impossibly tiny links).
~~~~~
My first issue with the games is the fact that you have to play from the Internet. This means you have to be able to access the Internet. I spend a lot of time in the subway here, and my phone has no connection with the outside world when I’m down there, so I don’t get to play games while I’m waiting for my trains to come, and that sucks. My second issue is that the touch screen, while very responsive for simple things like typing or dialing numbers, isn’t quite fast enough to properly keep up with the frantic pace of some of these games. Also, you have to have freakishly thin fingertips if you want to touch the screen with any precision.
~~~~~
That said, there is this one game, called iPipes, that I’m pretty addicted to. The goal is connect pipe pieces together before this toxic-looking ooze rolls through them. Simple, but fun. I was wondering if there are games available other than on the iTunes site, or if anyone has games that they would recommend? Thanks!
April 30th, 2008 - See Popular Posts for a sample iPhone web page which uses web server log scanning described here to create a clickable top ten list of the most popular weblog titles.
***
In an earlier post, Log Parsing II, I described scanning the Apache access log with Perl to build an html file containing Google searches of your site. Here’s a link to the complete example script:
The example script runs on Mac or Windows PC. It downloads the latest access logs to a local folder containing an archive of previously downloaded logs. It scans every log in the local archive folder. References to Google searches are written to an output file. When the local archive folder is completely scanned, the output HTML file is uploaded to the service provider’s host. The script should be run once per day. Many service providers keep the current access log plus one or two rotated logs.
***
Before running the script, change hostname, login name and password as needed. Also, change the script name from googleSearches_pl.txt to googleSearches.pl. If you don’t have Perl, you can download it free from ActiveState. Mac and Windows versions of Perl are availible for download. With Perl installed locally, the command to run the log scanning script is perl googleSearches.pl.
***
Output from the script should look something like [this]. The script contains a function named htmlBegin(). Use this function to set ”page title”, ”body title”, and “banner image” to any values desired.
***
Improving the Script
The obvious place to improve the script is to replace the multi-line regex with a single line regex for parsing the Apache log. A web page named A Simple Apache Log Parser contains an example of a single line Apache line parsing regex which looks promising. More to come……
***
About the Script
Reducing Noise - Access logs contains lots of “noise” that’s created when a web site is accessed by robots or when requests download pages composed of multiple images or javascript include files. Reducing noise provides a more realistic view of visits to the site.
***
Weblog noise reduction can be done by searching for and rejecting lines in the log containing words or strings we don’t really care about. How do you determine which words or strings indicate a line should be rejected? The best way may be to just look through the unfiltered access log. Simply eyeballing the unfiltered log will reveal plently of lines that can be classified as noise.
***
Once noise lines are identfied, choose words or strings that occur only in lines of noise and load the strings into an array or hash. Then build a function around it. The sample function below is from iPhone Cafe. Character strings are pushed onto the @discard array and a regex evaluates true for lines containing discard strings which returns false from the perl function causing the calling script to skipt the current line read another line from the access log.
#—————————————————————–
# Function: discard
# Purpose: Return true if the input line contains a character
# string indicating we dont care about the line of text.
#—————————————————————–
sub discard
{
my $lineOfText = shift;my $weDontCare = 0; # initialyze return variable
my @discard; # initialyze array to hold discard strings# Load the discard array
push(@discard, “ocadia”);
push(@discard, “themes”);
push(@discard, ‘24\.18\.’);
push(@discard, ‘76\.114\.206′);
push(@discard, ‘\.css’);
push(@discard, ‘\\/js’);
push(@discard, ‘\.png’);
push(@discard, ‘favicon\.ico’);
push(@discard, ‘\/image\/background’);
push(@discard, ‘wp-admin\/images’);# Compare the input line to the list of discard strings
foreach my $discardString (@discard) {
if ($lineOfText =~ /$discardString/i) {
$weDontCare = 1; # this line contains a word that eliminates it.
}
}return $weDontCare;
}
Related Pages:
Viruses, Spyware and other Nasties
My iPhone has been upgraded to version 1.1.3 so I thought it might be nice to start a list of things I like and don’t like about the new version of iPhone’s operating system……
***
What Works:
Not so Great:
Other notes: The site, Alternative Channel lets you make Web Clips for your iPhone.
Aptana’s iPhone development plug-in and the iUi Framework should be of interest to developers using Eclipse. See the full article on the IBM developer works site. Aptana’s iPhone studio is in beta.
While posting Generalized IPhone Contact Import, it occured to me that some iPhone owners may not have Microsoft Excel installed on their computer. Since Google’s free spreadsheet has the same file export capabilities as Excel, I thought it would be good to present another procedure for importing contacts to the iPhone. Microsoft Excel isn’t used here.
***
The import method presented here uses Google spreadsheet instead of Excel. The overall contact data flow is:
(1) Old Phone –> (2) plain file on your hard drive –>
(3) Google spreadsheet –> (4) CSV file on your hard drive –>
(5) Yahoo Address Book –> (6) Itunes/Iphone
There are lots of steps in this procedure some of which (step 5 below in particular) require manual copy/pasting of data. So, this method may not be worth the effort unless more than 20 or so contacts need to be moved. Also, since I’m not good with mobile phone SIM cards I don’t have specifics on moving contacts from SIM card to PC or Mac. However, I believe it can be done and have provided a Google search page for help. March 17 Note: See Move Contacts - Rokker to iPhone - Part 1 for specific steps to copy names and numbers from a Motorola SIM card to the MAC or PC.
***
The Google spreadsheet in step 4 contains three test contacts whose names are Jeff Z_Dilbert, Jim Z_Kirk, and Rick Z_Deckard. The last name of these test contacts begin with the letter Z to make it easy to remove them from the iPhone. This means you can test the import process any number of times using Jeff, Jim, and Rick by performing steps 6 - 12. Once things seem to be working okay, perform all 12 steps.
***
Follow these steps to import iPhone contacts:
Screen Snapshots
___
___
___
—
___
This post describes a general method to import IPhone contacts. To use it, you’ll need Microsoft Excel, and a Yahoo account and you’ll need to copy your contacts into Microsoft excel to get things started. A Yahoo account for free just for signing up.
***
Excel isn’t free, but it is widely used. If you don’t have access you Excel, you could use a plain text editor like Textpad. Another option is to use the free spreadsheet provided by Google Docs which supports saving in CSV format. See the bottom of this post for more on Google Docs or see Part II for another import process which is “Microsoft Office free” because it uses Google spreadsheet instead of Excel. Also, See “Move Contacts - Rokker to iPhone” for a post describing how to move contacts from your old cell phone to your PC without manually copy/pasting.
***
The general idea for contact import presented here is: 1. Move your contacts from Excel.csv to Yahoo contacts, 2. move contacts to Apple Itunes, and 3. synch to the IPhone. So the flow is Excel.csv–> Yahoo Contact Import –> Iphone Yahoo Sync.
***
A word of caution before using this procedure. To avoid moving unwanted or outdated contacts onto the IPhone, be sure the list of names and numbers in Yahoo Contacts contains only those contacts you want to see on your IPhone. I ran this procedure without first cleaning up my Yahoo contact list and ended up with lots and lots of old contacts moved to the IPhone. If you create a new Yahoo account specifically to import contacts from a spreadsheet to the IPhone, you shouldn’t have this problem.
***
As a first step, load your contacts into a Yahoo compatible Excel.csv file. You can download a sample Excel.csv file from [here]. After downloading the sample Excel.csv file, save it to your hard drive. Be carefull not to change values in row 1 of the spreadsheet. This row contains header values that are used during the import to Yahoo. The minimum data values (or columns) to be loaded into the .csv file are “first name”, “last name”, and “cell phone number”. Remaining fields can be blank.
***
After the Excel.csv file is populated, Login to your Yahoo account, go to the Address book, and select Import/Export. Go to the Import section and find the “Choose a program to import contacts from:“; it’s a drop-down list box. Select Microsoft Outlook (.CSV) File from the drop down and then use the Browse button to specify the location of the Excel CSV file containing your contact information.
***

When the Excel CSV file is located, Click Import Now. This should copy rows from the .csv file to your Yahoo address book.
***
Now, run ITunes and connect your IPhone to your computer. In Itunes, click the Info tab and locate the Sync Contact with: checkbox. Check this checkbox, and then select Yahoo Address Book from the associated dropdown. Then, Click the Sync button located in the lower right corner of the Info page. Enter your Yahoo ID and Password if prompted. The IPhone will sync in a few seconds.
***

Leave the IPhone connected to the computer, and click the Phone icon and then click Contacts.
***
As a final step, use your IPhone to verify it’s contact list now contains names and phone numbers from the Microsoft CSV file. If so, you should be good to go. If any part of this procedure doesn’t work as described, send a note to tony@core3.com.
***
Related Posts:
vCard to CSV Converter
***
Feb 16, 2008 - Instead of Excel or Textpad as the starting point for contact import, another option is to use the spreadsheet function of Google Docs. For instance, here’s the Yahoo_CSV_Import spreadsheet with column headers matching those expected by Yahoo’s contact import. To save the spreadsheet in CSV formation, select File->Export->CSV (shown below) which moves the spreadsheet into a second browser window. Then copy/paste from the second window to a text editor (notepad or textpad) and save to the local hard drive using any filename that ends in .csv. From this point, contacts can be imported into Yahoo’s address book in preparation for synching with the IPhone.
***
March 18, 2006 - See Move Contacts - Rokker to iPhone - Part 1 for steps to export names and numbers from the SIM card of your old cell phone using a SIM reader from Dekart. SIM data is written to a file on your PC or Mac in preparation for synching with iTunes and the iPhone.

Wouldn’t it be neat to run a script against the access logs of your web server to see what Google queries result in visits to your site? The output from such a log scanning script might look like [this] page where the timestamp and URL of Google driven visits are displayed. And, the URL is a link which is clicked to see the original Google search result as viewed by the person entering keywords into Google’s search page. A page like this can help the site owner understand, among other things, which topics are most popular and which pages are structured effectively.
***
In Apache Log Parsing I described a method to unpack web server log files so they could be analyzed for visitor traffic patterns. Since then, I’ve use the parser on my own web server logs and been looking through the output.
***
After a bit, I noticed something surprising in the logs. The referer section of certain log entries contained what appeared to be a Google search URL. This was confirmed by copy/pasting a few of these into my browser. Running the URLs in my browser produced a Google search page, and sure enough, somewhere on the Google page was a link to IPhone Cafe.
***
I thought, “Wow, assuming these aren’t robot transactions, I can now see what IPhone Cafe content is of greatest interest to real people”. Disabling IPhone’s autocorrect seems to be the number one topic. Many IPhone autocorrect searches originate in Europe. Moving contact information from old phone to iPhone is another popular topic.
***
I couldn’t afford to spend a bunch of time manually eyeballing access logs. So, I modified the log parsing script to open an output file and fill it with lines containing Google search URLs. While doing this, the script wraps HTML anchor tags around search URLs and then FTP’s the HTM file up to a folder on my ISP’s server.
***
The resulting, uploaded, Google search file is located [here]. The large fonts are formated for IPhone’s Safari browser but it still looks pretty much okay in a desktop browser. Clicking a link displays the original Google search from my web server access log. Pretty neat.
***
The Perl script which parses, formats, and does the ftp upload should work for just about any web site, IPhone related or not, so I’ll post the complete script [here] after cleaning it up a bit.
Tony
I’ve had my iPhone for maybe three weeks now, and I have more or less fallen in love with it, even though I’ve only used the most basic functions. I’d like to test drive some games on the thing, although I’m the first to admit that, as a grad student, I hardly need to be throwing my rare spare time into the time pit that is hand held gaming. I’ve not got any music, no videos, nothing like that, and I still think it’s the coolest thing ever.
***
I’ve also discovered that having an iPhone is at the least a good way to break the ice in a crowd, and at best, makes one–however momentarily–the most popular person in the room. My first experience with this came just last Wednesday, while at a beer tasting and pizza party. This one guy whipped out his Blackberry and started showing it off to the people aro