CiUI is an iPhone code library which helps developers create web applications with the look and feel of Apple’s iPhone. It was modeled after iUI and is used by CNET. CiUI supports horizontal scrolling menu’s which are the trademark of the iPhone’s user interface. With CiUI, a web developer can build Safari web browser applications that look like a built in iPhone application.
***
The CiUI Safari page has another option which is labeled “Popular Posts”. Here’s a link to the page (use an iPhone or Firefox):
http://www.core3.com/icore/i/
Clicking “Popular Posts” uses CiUI’s Javascript and CSS framework to display a list of titles ranked by the number of times the post has been downloaded.

***
In the example below, “Turn off autocorrect” is the number one downloaded post. Click a title to see post content.

***
Data to drive the top ten list doesn’t come from the WordPress MySQL database. Instead, it comes from the web server access log.
***
In an earlier post, a Perl script to parse the web server log file was presented. The lines below add to that earlier Perl script by incrementing a hash named %count_Popular.
***
After the hash is populated, the following lines sort the hash and write the first 40 lines into a file named popular.txt.
***
The file, popular.txt is then FTP’d up to the ISP server and used as input to drive the “Popular Posts” menu page. Here’s the file:
http://www.core3.com//icore/access/popular.txt
Each line of popular.txt is converted into a menu option.