routing mechanism in jQuery