diff --git jcalendar/jcalendar.js jcalendar/jcalendar.js
index f951f98..b1372d5 100644
--- jcalendar/jcalendar.js
+++ jcalendar/jcalendar.js
@@ -39,15 +39,10 @@ if (Drupal.jsEnabled) {
       // Show Popup
       $('#calpopup').fadeIn('slow');
 
-      // If sucessful call this
-      function domCallback(msg) {
-        $('#calpopup-body').html(msg);
-      }
-
       // Get NodeID and ItemID
-      var ids = $(this).parent().parent().attr('class');
-      var arrs = ids.split(" ");
-      var arr = arrs[0].split(".");
+      var parents = $(this).parents('.calendar');
+      var ids = $(parents[0]).attr('id');
+      var arr = ids.split(".");
       var nid = arr[1];
       var id = arr[4];
 
@@ -56,7 +51,7 @@ if (Drupal.jsEnabled) {
         type: "GET",
         url: Drupal.settings.basePath + "?q=jcalendar/getnode/"+nid+"/"+ids,
         success: function(msg){
-          domCallback(msg);
+          $('#calpopup-body').html(msg);
         }
       });
 
@@ -74,8 +69,7 @@ if (Drupal.jsEnabled) {
           $(document).unbind("click");
         }
       });
-
-      // Don't Follow the real link
+      // Don't follow the real link or make a big stink.
       return false;
     });
   });