<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
 
 <title>Pratham.name</title>
 <link href="http://feeds.feedburner.com/pratham" rel="self"/>
 <link href="http://www.pratham.name/"/>

 <updated>2011-09-05T02:12:08+05:30</updated>
 <id>http://www.pratham.name/</id>
 <author>
   <name>Pratham Kumar</name>
 </author>

	
     <entry>
	   <title>Most popular web browser by country</title>
		<link href="http://www.pratham.name/most-popular-web-browser-by-country.html"/>
	  </entry>
	
     <entry>
	   <title>Check if your mobile number affected by the 2G license cancellations</title>
		<link href="http://www.pratham.name/check-if-your-mobile-number-affected-by-the-2g-license-cancellations.html"/>
	  </entry>
	
     <entry>
	   <title>Optimizing App Engine datastore reads</title>
		<link href="http://www.pratham.name/optimizing-app-engine-datastore-reads.html"/>
	  </entry>
	
 
 <entry>
   <title>App engine charts Greasemonkey script</title>
   <link href="http://www.pratham.name/app-engine-chart-greasemonkey-script.html"/>
   <updated>2011-08-25T00:00:00+05:30</updated>
   <id>http://www.pratham.name/app-engine-chart-greasemonkey-script</id>
   <content type="html">&lt;p&gt;For everyone who manages more than a few &lt;a href='http://code.google.com/appengine'&gt;App engine&lt;/a&gt; applications, this greasemonkey script adds an inline chart to each app-id on the dashboard. This way you don&amp;#8217;t have to click through to each application page.&lt;/p&gt;

&lt;p&gt;&lt;img src='/images/gae-greasemonkey.png' alt='GAE demo' /&gt;&lt;/p&gt;
&lt;div class='highlight'&gt;&lt;pre&gt;&lt;code class='javascript'&gt;&lt;span class='c1'&gt;// ==UserScript==&lt;/span&gt;
&lt;span class='c1'&gt;// @name          GAE graphs&lt;/span&gt;
&lt;span class='c1'&gt;// @namespace     pratham.name&lt;/span&gt;
&lt;span class='c1'&gt;// @description   Adds inline graphs for GAE apps&lt;/span&gt;
&lt;span class='c1'&gt;// @include       https://appengine.google.com/&lt;/span&gt;
&lt;span class='c1'&gt;// @include       http://appengine.google.com/&lt;/span&gt;
&lt;span class='c1'&gt;// @require       http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js&lt;/span&gt;
&lt;span class='c1'&gt;// ==/UserScript==&lt;/span&gt;

&lt;span class='kd'&gt;function&lt;/span&gt; &lt;span class='nx'&gt;main&lt;/span&gt;&lt;span class='p'&gt;()&lt;/span&gt; &lt;span class='p'&gt;{&lt;/span&gt;
  &lt;span class='nx'&gt;$&lt;/span&gt;&lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='s1'&gt;&amp;#39;a[title=&amp;quot;view dashboard&amp;quot;]&amp;#39;&lt;/span&gt;&lt;span class='p'&gt;).&lt;/span&gt;&lt;span class='nx'&gt;each&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='kd'&gt;function&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='nx'&gt;index&lt;/span&gt;&lt;span class='p'&gt;)&lt;/span&gt; &lt;span class='p'&gt;{&lt;/span&gt;
		&lt;span class='kd'&gt;var&lt;/span&gt; &lt;span class='nx'&gt;link&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='nx'&gt;$&lt;/span&gt;&lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='k'&gt;this&lt;/span&gt;&lt;span class='p'&gt;);&lt;/span&gt;
		&lt;span class='kd'&gt;var&lt;/span&gt; &lt;span class='nx'&gt;href&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='nx'&gt;link&lt;/span&gt;&lt;span class='p'&gt;.&lt;/span&gt;&lt;span class='nx'&gt;attr&lt;/span&gt;&lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='s1'&gt;&amp;#39;href&amp;#39;&lt;/span&gt;&lt;span class='p'&gt;);&lt;/span&gt;

		&lt;span class='nx'&gt;$&lt;/span&gt;&lt;span class='p'&gt;.&lt;/span&gt;&lt;span class='nx'&gt;get&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='nx'&gt;href&lt;/span&gt;&lt;span class='p'&gt;,&lt;/span&gt; &lt;span class='kd'&gt;function&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='nx'&gt;data&lt;/span&gt;&lt;span class='p'&gt;)&lt;/span&gt; &lt;span class='p'&gt;{&lt;/span&gt;
			&lt;span class='kd'&gt;var&lt;/span&gt; &lt;span class='nx'&gt;str&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='nx'&gt;data&lt;/span&gt;&lt;span class='p'&gt;.&lt;/span&gt;&lt;span class='nx'&gt;match&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='sr'&gt;/ae-dash-graph-img[\s\S]*chd=e:.*,(.*).chxp/i&lt;/span&gt;&lt;span class='p'&gt;)&lt;/span&gt; &lt;span class='p'&gt;[&lt;/span&gt;&lt;span class='mi'&gt;1&lt;/span&gt;&lt;span class='p'&gt;];&lt;/span&gt;
			&lt;span class='kd'&gt;var&lt;/span&gt; &lt;span class='nx'&gt;url&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='s1'&gt;&amp;#39;http://chart.apis.google.com/chart?cht=lc&amp;amp;chs=100x25&amp;amp;chd=e:&amp;#39;&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='nx'&gt;str&lt;/span&gt;&lt;span class='p'&gt;;&lt;/span&gt;
			&lt;span class='nx'&gt;link&lt;/span&gt;&lt;span class='p'&gt;.&lt;/span&gt;&lt;span class='nx'&gt;parent&lt;/span&gt; &lt;span class='p'&gt;().&lt;/span&gt;&lt;span class='nx'&gt;append&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='s1'&gt;&amp;#39; &amp;lt;img src=&amp;quot;&amp;#39;&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='nx'&gt;url&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='s1'&gt;&amp;#39;&amp;quot;&amp;gt;&amp;#39;&lt;/span&gt;&lt;span class='p'&gt;);&lt;/span&gt;
		&lt;span class='p'&gt;});&lt;/span&gt;
	&lt;span class='p'&gt;});&lt;/span&gt;
&lt;span class='p'&gt;}&lt;/span&gt;

&lt;span class='c1'&gt;// load jQuery and execute the main function&lt;/span&gt;
&lt;span class='nx'&gt;main&lt;/span&gt; &lt;span class='p'&gt;();&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;&lt;a href='/images/gae.user.js'&gt;Install GAE graphs script&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Note that this script uses the &amp;#8220;require&amp;#8221; feature of Greasemonkey, so it won&amp;#8217;t work on Google Chrome.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>EveryDNS to shut down in August</title>
   <link href="http://www.pratham.name/everydns-to-shut-down.html"/>
   <updated>2011-06-08T00:00:00+05:30</updated>
   <id>http://www.pratham.name/everydns-to-shut-down</id>
   <content type="html">&lt;p&gt;&lt;a href='http://www.everydns.com/'&gt;EveryDNS&lt;/a&gt;, my DNS host of choice, has &lt;a href='http://dyn.com/faqs-everydns-migration-to-dyn-free-users'&gt;informed its users that it will shut shop on August 31&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href='http://www.dyndns.com/'&gt;DynDNS&lt;/a&gt;, the new owners, will charge a 5$ redeemable fee for this transfer. Apart from that each hosted domain will cost 30$ per year (20$ for the first year). Note that EveryDNS used to be free for 20 domains.&lt;/p&gt;

&lt;p&gt;I&amp;#8217;ll be moving my hosted domains to &lt;a href='http://www.namecheap.com/products/freedns.aspx'&gt;Namecheap FreeDNS&lt;/a&gt;, who I anyway use as my domain registrar.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>Rajiv is the most common India CEO name</title>
   <link href="http://www.pratham.name/rajiv-most-common-indian-ceo-name.html"/>
   <updated>2011-04-29T00:00:00+05:30</updated>
   <id>http://www.pratham.name/rajiv-most-common-indian-ceo-name</id>
   <content type="html">&lt;p&gt;&lt;img src='/images/linked-ceo-names.png' alt='Indian CEO names' /&gt;&lt;/p&gt;

&lt;p&gt;According to LinkedIn, the name &amp;#8220;Rajiv&amp;#8221; is the &lt;a href='http://www.alootechie.com/?q=content/most-ceos-india-are-named-rajiv-linkedin'&gt;most common Indian CEO name&lt;/a&gt;. Oddly, the name &amp;#8220;Rajeev&amp;#8221; - an alternate spelling for &amp;#8220;Rajiv&amp;#8221; - also comes in at no. 8.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>Django 0.96 documentation mirror</title>
   <link href="http://www.pratham.name/django-096-documentation.html"/>
   <updated>2011-03-08T00:00:00+05:30</updated>
   <id>http://www.pratham.name/django-096-documentation</id>
   <content type="html">&lt;p&gt;Django recently deleted the documentation of the 0.96 version, the very same version that Google App Engine uses for its default templating engine. Luckily someone has &lt;a href='http://django096docs.appspot.com/'&gt;mirrored the entire documentation&lt;/a&gt;.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>Review umpiring errors with Bad Umpire</title>
   <link href="http://www.pratham.name/bad-umpire.html"/>
   <updated>2011-03-04T00:00:00+05:30</updated>
   <id>http://www.pratham.name/bad-umpire</id>
   <content type="html">&lt;p&gt;&lt;img src='/images/badumpire.png' alt='Bad Umpire' /&gt;&lt;/p&gt;

&lt;p&gt;Did a cricket umpire commit a major error ? Now share your feelings on &lt;a href='http://www.badumpire.com/'&gt;Bad Umpire&lt;/a&gt;.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>Normalizing free form text input</title>
   <link href="http://www.pratham.name/normalizing-free-text-input.html"/>
   <updated>2011-02-08T00:00:00+05:30</updated>
   <id>http://www.pratham.name/normalizing-free-text-input</id>
   <content type="html">&lt;p&gt;If you&amp;#8217;re accepting free text from users that needs make sense, you need to normalize it. For instance, if you&amp;#8217;re accepting the name of a film actor, you need to understand that &amp;#8220;Shahrukh Khan&amp;#8221;, &amp;#8220;Shah rukh Khan&amp;#8221;, &amp;#8220;SRK&amp;#8221; or even &amp;#8220;Sharukh Khan&amp;#8221; point to the same actor.&lt;/p&gt;

&lt;p&gt;You could use a dynamic drop-down to force a certain style of text-entry, but that gets a little intrusive.&lt;/p&gt;

&lt;p&gt;Here I demonstrate a simple way to ensure consistency of this data without any intrusive UI elements. I&amp;#8217;m using the &lt;a href='http://www.bing.com/developers'&gt;Bing API&lt;/a&gt;, but any search API would do.&lt;/p&gt;

&lt;p&gt;For film actors, I&amp;#8217;ll use IMDB since it&amp;#8217;s comprehensive and exclusive.&lt;/p&gt;
&lt;div class='highlight'&gt;&lt;pre&gt;&lt;code class='python'&gt;&lt;span class='kn'&gt;import&lt;/span&gt; &lt;span class='nn'&gt;urllib&lt;/span&gt;
&lt;span class='kn'&gt;import&lt;/span&gt; &lt;span class='nn'&gt;re&lt;/span&gt;

&lt;span class='n'&gt;APPID&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='s'&gt;&amp;#39;YOUR-BING-API-ID&amp;#39;&lt;/span&gt;
&lt;span class='n'&gt;val&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='s'&gt;&amp;#39;Shahrukh Khan&amp;#39;&lt;/span&gt;

&lt;span class='c'&gt;# quick bing search with site:imdb.com parameter.&lt;/span&gt;
&lt;span class='n'&gt;url&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='s'&gt;&amp;#39;http://api.search.live.net/xml.aspx?Appid=&amp;#39;&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='n'&gt;APPID&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='s'&gt;&amp;#39;&amp;amp;query=&amp;#39;&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='n'&gt;urllib&lt;/span&gt;&lt;span class='o'&gt;.&lt;/span&gt;&lt;span class='n'&gt;quote_plus&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='s'&gt;&amp;#39;site:imdb.com &amp;#39;&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='n'&gt;val&lt;/span&gt;&lt;span class='p'&gt;)&lt;/span&gt;&lt;span class='o'&gt;+&lt;/span&gt;&lt;span class='s'&gt;&amp;#39;&amp;amp;sources=web&amp;amp;web.count=1&amp;amp;adult=off&amp;#39;&lt;/span&gt;
&lt;span class='n'&gt;response&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='n'&gt;urllib&lt;/span&gt;&lt;span class='o'&gt;.&lt;/span&gt;&lt;span class='n'&gt;urlopen&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='n'&gt;url&lt;/span&gt;&lt;span class='p'&gt;)&lt;/span&gt;

&lt;span class='c'&gt;# a simple regex (IMDB has &amp;quot;&amp;lt;actor&amp;gt; - IMDB&amp;quot; as title) and we have the normalized name.&lt;/span&gt;
&lt;span class='n'&gt;normalizedName&lt;/span&gt; &lt;span class='o'&gt;=&lt;/span&gt; &lt;span class='n'&gt;re&lt;/span&gt;&lt;span class='o'&gt;.&lt;/span&gt;&lt;span class='n'&gt;findall&lt;/span&gt; &lt;span class='p'&gt;(&lt;/span&gt;&lt;span class='s'&gt;&amp;#39;&amp;lt;web:Title&amp;gt;(.*) -&amp;#39;&lt;/span&gt;&lt;span class='p'&gt;,&lt;/span&gt; &lt;span class='n'&gt;response&lt;/span&gt;&lt;span class='o'&gt;.&lt;/span&gt;&lt;span class='n'&gt;read&lt;/span&gt; &lt;span class='p'&gt;())&lt;/span&gt; &lt;span class='p'&gt;[&lt;/span&gt;&lt;span class='mi'&gt;0&lt;/span&gt;&lt;span class='p'&gt;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;</content>
 </entry>
 
 <entry>
   <title>RBI cripples PayPal in India</title>
   <link href="http://www.pratham.name/rbi-cripples-paypal-in-india.html"/>
   <updated>2011-01-28T00:00:00+05:30</updated>
   <id>http://www.pratham.name/rbi-cripples-paypal-in-india</id>
   <content type="html">&lt;p&gt;After struggling to comply with Indian regulations for the past year or so, it seems RBI has fatally crippled PayPal. In &lt;a href='http://www.paypal-apac.com/india/'&gt;an email to all its Indian users&lt;/a&gt;, PayPal notifies us about the upcoming changes.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;With effect from 1 March 2011, you are required to comply with the requirements set out in the notification of the Reserve Bank of India governing the processing and settlement of export-related receipts facilitated by online payment gateways (&amp;#8220;RBI Guidelines&amp;#8221;).&lt;/p&gt;

&lt;p&gt;In order to comply with the RBI Guidelines, our user agreement in India will be amended for the following services as follows:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Any balance in and all future payments into your PayPal account &lt;strong&gt;may not be used to buy goods or services&lt;/strong&gt; and &lt;strong&gt;must be transferred to your bank account in India within 7 days&lt;/strong&gt; from the receipt of confirmation from the buyer in respect of the goods or services; and&lt;/li&gt;

&lt;li&gt;Export-related payments for goods and services into your PayPal account &lt;strong&gt;may not exceed US$500 per transaction&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;

&lt;p&gt;This is very bad news for scores of Indian freelancers/SMBs which rely heavily on PayPal for international payments.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>Mobile Number Portability finally goes live today</title>
   <link href="http://www.pratham.name/mobile-number-portability-goes-live.html"/>
   <updated>2011-01-20T00:00:00+05:30</updated>
   <id>http://www.pratham.name/mobile-number-portability-goes-live</id>
   <content type="html">&lt;p&gt;After what has seemed an eternity, Mobile number portability &lt;a href='http://www.thehindu.com/news/article1103230.ece'&gt;will finally go live today&lt;/a&gt;. The MNP, which has already missed three deadlines last year, was introduced in Haryana as a pilot case in November. Since then, as the deadline approached, major player have started campaigns to woo prospective users.&lt;/p&gt;

&lt;p&gt;Just in case you&amp;#8217;re not informed, here&amp;#8217;s what MNP is and is not.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You can &lt;strong&gt;retain your number&lt;/strong&gt; while moving from network to network. Or from pre-paid to post-paid. Or GSM to CDMA.&lt;/li&gt;

&lt;li&gt;It will cost you &lt;strong&gt;Rs 19&lt;/strong&gt;.&lt;/li&gt;

&lt;li&gt;The whole process will take &lt;strong&gt;upto 4 days&lt;/strong&gt;, during which your number stays disconnected.&lt;/li&gt;

&lt;li&gt;You cannot switch telecom circles with MNP (yet).&lt;/li&gt;

&lt;li&gt;You cannot carry over pre-paid balances.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Operators, having long held post-paid users captive by their numbers, will be forced to offer better voice/data plans or risk losing them to competing networks.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>Anatomy of a WordPress Theme</title>
   <link href="http://www.pratham.name/anatomy-of-a-wordpress-theme.html"/>
   <updated>2011-01-13T00:00:00+05:30</updated>
   <id>http://www.pratham.name/anatomy-of-a-wordpress-theme</id>
   <content type="html">&lt;p&gt;&lt;img src='/images/wp-anatomy.png' alt='WordPress Theme' /&gt;&lt;/p&gt;

&lt;p&gt;If you&amp;#8217;ve ever had to dig into the internals of a WordPress theme, this is &lt;a href='http://yoast.com/wordpress-theme-anatomy/'&gt;a priceless infographic&lt;/a&gt;.&lt;/p&gt;</content>
 </entry>
 
 <entry>
   <title>Simple HTML internet status checker</title>
   <link href="http://www.pratham.name/simple-html-internet-status-checker.html"/>
   <updated>2011-01-01T00:00:00+05:30</updated>
   <id>http://www.pratham.name/simple-html-internet-status-checker</id>
   <content type="html">&lt;p&gt;My BSNL internet connection has been especially flaky lately, so I&amp;#8217;ve written this simple HTML script to notify me when internet is back up.&lt;/p&gt;
&lt;div class='highlight'&gt;&lt;pre&gt;&lt;code class='html'&gt;&lt;span class='nt'&gt;&amp;lt;html&amp;gt;&lt;/span&gt;
&lt;span class='nt'&gt;&amp;lt;head&amp;gt;&lt;/span&gt;
  &lt;span class='nt'&gt;&amp;lt;meta&lt;/span&gt; &lt;span class='na'&gt;http-equiv=&lt;/span&gt;&lt;span class='s'&gt;&amp;quot;refresh&amp;quot;&lt;/span&gt; &lt;span class='na'&gt;content=&lt;/span&gt;&lt;span class='s'&gt;&amp;quot;60&amp;quot;&lt;/span&gt;&lt;span class='nt'&gt;&amp;gt;&lt;/span&gt;
&lt;span class='nt'&gt;&amp;lt;/head&amp;gt;&lt;/span&gt;
&lt;span class='nt'&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
  &lt;span class='nt'&gt;&amp;lt;img&lt;/span&gt; &lt;span class='na'&gt;src=&lt;/span&gt;&lt;span class='s'&gt;&amp;quot;http://www.example.com/icons/a.gif&amp;quot;&lt;/span&gt; &lt;span class='na'&gt;onload=&lt;/span&gt;&lt;span class='s'&gt;&amp;quot;location.href = &amp;#39;http://www.welcometointernet.org/&amp;#39;;&amp;quot;&lt;/span&gt;&lt;span class='nt'&gt;&amp;gt;&lt;/span&gt;
&lt;span class='nt'&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;
&lt;span class='nt'&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;p&gt;The page tries to load &lt;a href='http://www.example.com/a.gif'&gt;an image&lt;/a&gt;, and if successful redirects to &lt;a href='http://www.welcometointernet.org/'&gt;this site&lt;/a&gt; (WARNING: loud sound). If not, it tries again in 60 seconds.&lt;/p&gt;</content>
 </entry>
 
 
</feed>
