Kerala Church

Kerala Church

The faithful at a church in Kerala on Christmas

Posted in: photography, travel by hypnos No Comments

Taaza, alias Fresh

Taaza, alias Fresh

The tea gardens of Munnar are a delight! Miles and miles of greenery wherever you look, and a steaming hot cup of Kanan Devan tea. What else do you need?

Recaptured on Facebook

Yes friends, I have finally succumbed to the lure of Facebook.

If you are on Facebook and like my photography, please Like my photography page on Facebook here, and also recommend me to your friends.

The blog will continue to be updated as it has been (hopefully more frequently now), while I will be updating one photograph, either brand new or from the archives, on the Facebook page every day.

Have A Lush Green New Year!

Have A Lush Green New Year!

This time I didn’t want to spoil the beauty of Kerala with a calendar or any other text :)

Enjoy the lush green tea gardens of Munnar.

Wallpaper 1280×800
Wallpaper 1366×768
Wallpaper 1650×1080
Wallpaper 1920×1200
Wallpaper 2560×1440

Fly Away!

Fly Away!

Just another flying black duck at the Backwaters near Kottayam, Kerala!

Home of Karthik

Home of Karthik

I’m back from a 5 day trip to Kerala. Lots of beautiful pictures coming up.

Till then, here’s a picture of The Subramaniaswamy Temple, Perunna.

Have a Happy Christmas!


Wallpaper 1280×800
Wallpaper 1366×768
Wallpaper 1366×768
Wallpaper 1366×768
Wallpaper 1366×768

jQuery tip: all ready?

I came across this post about a common jQuery mistake by Michael Tran, and found it interesting. Yes, you need to load your jQuery library before you load your jQuery-specific-scripts or they would not work.

But here’s a mistake I commit often, of treating the event binding declarations as function declarations. Often I write code like this:

<script>
  $("#button").click( function() {
    alert("clicked!");
  });
</script>

And then wonder why nothing happens when I click on <input type="button" id="button" value="Click me!">. Well, that is because the $("#button").click(…); code never gets executed!

Executed? Exactly. As I said it’s not a function. The function is already defined as function() {…}, right? We need to execute the jQuery event binding. When? As soon as the document is ready. How? Nine ways to skin the cat, three (as far as I know) to tackle this problem.

  1. In the body tag
    Simply put,

     <script>
      function loadingRoutine() {
        $("#button").click( function() {
          alert("clicked!");
        });
      }
    </script>
    <body onLoad="loadingRoutine();"> 

    But this means contaminating your markup with behavioral code. I, never!

  2. Using a jQuery event
    The onLoad event has a different name in jQuery: $(document).ready();. You use it thus:

     <script>
      $(document).ready( function() {
        $("#button").click( function() {
          alert("clicked!");
        });
      });
    </script> 

    This way you don’t have to put any javascript in your body tag.

    You can also use jQuery(document).ready(…); instead, but $(… is shorter and faster, innit?

    What really happens here is that the moment the HTML document is ready the $(document).ready(); event is triggered, much like the body’s onLoad event, and it binds all your jQuery behaviours to the events as you wanted.

  3. jQuery shortcut
    It’s the same $(document).ready(); event, but this time it’s way shorter, cuter and faster. It is $(…);. The usage:

     <script>
      $( function() {
        $("#button").click( function() {
          alert("clicked!");
        });
      });
    </script> 

There’s another way to call the $(document).ready(…); event: $().ready();, but the jQuery documentation advises against it. And who needs $().ready(); when you have $();?

Just another fun evening

Just another fun evening
Just another fun evening, by recaptured

Posted in: photography by hypnos No Comments , , ,

Long Due Update

I’m sorry I’ve not been writing for quite some time now. But I hope you enjoy the pictures and the wallpapers :-)

In the past few months, life has changed. A bit.

I’m working for myself now. And I’m happier doing it.

You’d have seen the post about the Big Wheels Motoring website design. Apart from that I’ve worked with a design agency in Pune run by very dear friends of mine, on a website for a NGO. And the most exciting thing right now is another project with the same agency, this time for another friend. You shall see the result in a couple of weeks.

And, I am hell-bent on getting another personal web project out this time. Wish me luck!

Posted in: business, design, narcissism, news by hypnos No Comments

Switch to our mobile site