Archive for May, 2007

Using CAPTCHA to digitize books

Thursday, May 31st, 2007

I just came across this new service called reCAPTCHA which provides you with a service to embed CAPTCHA codes in your application. The cool part of this service is that it uses the CAPTCHA codes to actually digitize words which an OCR software couldn’t read. The project currently helps digitize books from the Internet Archive

reCAPTCHA improves the process of digitizing books by sending words that cannot be read by computers to the Web in the form of CAPTCHAs for humans to decipher. More specifically, each word that cannot be read correctly by OCR is placed on an image and used as a CAPTCHA. This is possible because most OCR programs alert you when a word cannot be read correctly.

But if a computer can’t read such a CAPTCHA, how does the system know the correct answer to the puzzle? Here’s how: Each new word that cannot be read correctly by OCR is given to a user in conjunction with another word for which the answer is already known. The user is then asked to read both words. If they solve the one for which the answer is known, the system assumes their answer is correct for the new one. The system then gives the new image to a number of other people to determine, with higher confidence, whether the original answer was correct.

Link: http://recaptcha.net

Google Gears for offline apps

Thursday, May 31st, 2007

Google has released a beta version of Google Gears which is an open source browser extension which  enables web applications to provide offline functionality using following JavaScript APIs.

Here’s what you can do with the API’s:

  • Store and serve application resources locally
  • Store data locally in a fully-searchable relational database
  • Run asynchronous Javascript to improve application responsiveness

You can take a look at the sample applications at http://code.google.com/apis/gears/sample.html once you install the browser plugin.

The news out there is that Google’s planning to offer offline support for their current applications like Google Reader, Docs & Spreadsheets.

Zend Framework 1.0.0 RC Released

Wednesday, May 30th, 2007

It’s been a long wait for the 1.0 version of the Zend framework! The team has announced the  released of 1.0.0 release candidate version, so the actual release of the actual 1.0 version’s not too far off.

Some noteworthy improvements in this release, include:

  • Zend_Filter_Input, a “cage” for validating input data
  • Zend_Validate supports user-definable error messages
  • Zend_Gdata redesigned interface allows a convenient object-oriented usage
  • MVC ViewRenderer makes it much simpler to write controller actions

Download Zend Framework 1.0.0 Release Candidate.

Ubuntu (Fiesty Fawn) on a HP nx6325 laptop

Wednesday, May 30th, 2007

Last week I’d finally decided to move off from Windows on my work laptop. After the default installation off the 64 bit CD, here were some of the problems I found:

  • The default Wireless drivers didn’t seem to work at all.
  • The 64 bit version of the OS seemed to lack some of the softwares like Flash player and w32codecs.
  • The external monitor/projecter didn’t work off the default installation.
  • My development stack of LAMP had to be installed manually.
  • Very basic multimedia support.

I reinstalled the laptop with the 32-bit OS instead, to get a hold of the missing software on the 64 bit version. The wireless was still down. A quick google search landed me at the following blog, which had a great step-by-step instruction on how to get ndiswrapper and the windows version of the Broadcom wireless driver to work on the laptop.
Instruction for installing the Broadcom drivers through ndiswrapper: http://vale.homelinux.net/wordpress/?p=144

To get the external display working, I followed the instructions over at Ubuntu’s community help site: https://help.ubuntu.com/community/BinaryDriverHowto/ATI.
The default open source drivers didn’t have support for TV-out. The instructions I followed were quite simple:

Install linux-restricted-modules and restricted-manager provied in the restricted repositories:
sudo apt-get update
sudo apt-get install linux-restricted-modules-generic restricted-manager

Open the restricted drivers manager included in 7.04 “System -> Administration -> Restricted Drivers Manager” and select “ATI accelerated graphics driver”. This will hopefully enable fglrx in a painless way. If not, follow the instructions for Edgy.

Apart from the instructions above you’ll also have to install fglrx-control. At the shell prompt type in:

sudo apt-get install fglrx-control

After this you can access the ATI control panel by issuing the following command at the prompt.

sudo fireglcontrol

These took care of my basic necessities. Had my network and basic software installed. Being a LAMP developer, I had to get LAMP installed on the laptop. Here’s how to get it done:

apt-get install apache2
apt-get install php5 libapache2-mod-php5
apt-get install php5-cli php5-dev
apt-get install php-pear

The first two gets apache2, and the php modules installed. The next two get the php command line, php dev libraries and pear installed on the system. Next let’s get MySQL up and running:

apt-get install mysql-server mysql-client

This installs MySQL server and the client setup. To setup the mysql libraries for PHP5, run the following:

apt-get install php5-mysql

Linux still lacks an IDE for LAMP development, so while I search the net for a suitable candidate, I guess gedit or Quanta will work fine for coding. :) One of the candidates in the open source area for this task is PDT, I’m yet to evaluate it.

To get all the other multimedia goodies installed on my system, I used BUMPS.

If your company has some nagging legacy web applications which refuse to work on anything other than IE, you can also install IE on Ubuntu using ies4linux. Here’s a link which shows you how do go about this:

http://www.psychocats.net/ubuntu/ies4linux

Be warned that having IE on your system legally requires that you have a valid license for Windows.

If you’re pulling out your hair wondering why the hell will some one install IE on Linux, it’s just that some nasty web-application developers make cross-browser compatible apps that work on any browser as long as it is IE!


A large number of wireless broadband services like sprint wireless and verizon wireless have sprouted with increasing trend of wireless. Also, with the advent of wireless internet hotspots, wireless internet coverage has expanded.

PHPLiveX - Tutorial

Friday, May 18th, 2007

If you’re looking for the quickest way to get your PHP functionality Ajax enabled, you’ve got to take a look at PHPLiveX. It greatly simplifies the process of Ajaxifying your PHP code without knowing Javascript code.

Let’s see how to Ajaxify a simple PHP function. Let’s create a simple function to output the server time:
function myServerTime(){
return date("D M j G:i:s T Y");
}

First you have to include the PHPLiveX library and register your function. Here’s how to to it:
include 'PHPLiveX.php';

function myServerTime(){
return date("D M j G:i:s T Y");
}

$phplive = new PHPLiveX("myServerTime"); //Register the function with PHPLiveX
?>

$phplive = new PHPLiveX(”myServerTime”); is used to register our function myServerTime with PHPLiveX

Next let’s build our HTML Display. Let’s keep it simple, but allowing the user to click a link to get the updated server time:

Get Server Time

Now we’ll have to create areas to display our Loading Status and the results back from the server. Let’s create two divs for this.



You’ll notice that the loading span’s visibility has been set to hidden by default. PHPLiveX will use this to show the loading indicator when an action is being performed.

Now let’s get the entire HTML created. PHPLiveX autogenerates the Javascript required to create the AJAX calls, this has to take place in the html head section. To generate the Javascript all you need to call is $phplive->Run(). So let’s get to the entire script with the HTML:

include 'PHPLiveX.php';

function myServerTime(){
return date("D M j G:i:s T Y");
}

$phplive = new PHPLiveX("myServerTime"); //Register the function with PHPLiveX
?>



Get Server Time





You’ll notice that in the Get Server Time link there’s a little bit of Javascript - javascript:myServerTime(”, ‘target=serverResult,preload=loading’);. That’s used to call the myServerTime function from Javascript. The first parameter is null since our function myServerTime doesn’t accept any parameters. The second parameter tells PHPLiveX to send the output to the “serverResult” div and use the “loading” div as the preloader.

That’s it ! You can see a demo of this here.
Get the source code for this tutorial here. This includes version 2.2 of the PHPLiveX library.

I’ll put up a tutorial on how to use PHPLiveX for a whois lookup next week.

Link to PHPLiveX: PHPLiveX -> An Open Source PHP/Ajax Library

Google Analytics’ new Version

Thursday, May 17th, 2007

Google Analytics New UI

I just got a mail from the Google Analytics team today about their new version which is available. The new UI’s are really out of this world. For those of us who were really confused with their older menu system will be really blown away with their new UI which is much simpler to use an navigate around.

Their earlier canned summary page now gives way to your custom dashboard where you can place the reports you want to see. The map overlay is more interactive now allowing you to drill down to countries and cities.

Here are the other improvements (as per the GA team’s email):

  • Email and export reports: Schedule or send ad-hoc personalized report emails and export reports in PDF format.
  • Custom Dashboard: No more digging through reports. Put all the information you need on a custom dashboard that you can email to others.
  • Trend and Over-time Graph: Compare time periods and select date ranges without losing sight of long term trends.
  • Contextual help tips: Context sensitive Help and Conversion
  • University tips are available from every report.

The new interface has everything the previous interface had and more. In addition, links within reports make it easier to navigate related information and explore your data.

If you haven’t checked your Google Analytics account recently, head over there now and check it out.

GA Flash demo: http://www.google.com/analytics/media/report_tour/feature_tour.html
GA Features page: http://www.google.com/analytics/features.html
Google Analytics Blog Post : http://analytics.blogspot.com/2007/05/new-version-of-google-analytics.html

Vacation Snaps @ Flickr

Monday, May 7th, 2007


Fog Cover
Originally uploaded by Vinu Thomas.

I’ve uploaded my latest vacation snaps over at Flickr. You can take a look at the snaps at:
http://www.flickr.com/photos/vinut/sets/72157600185194924/

The photos were taken at Kodaikanal, a hill-station at Tamil Nadu. The place was quite crowded when we went there last week. I guess everyone was looking at beating the heat and running over to Kodai. :)

About Me

Here's my blog on stuff I keep finding on the Web. More

Want to subscribe?

 Subscribe in a reader Or, subscribe via email:
Enter your email address:  
On the Go? Get this on your Widsets: Add to my Widsets
Find entries :