--- link.module.orig	2008-07-21 16:11:21.000000000 -0400
+++ link.module	2008-07-21 16:44:13.000000000 -0400
@@ -155,6 +155,8 @@
         'url' => array('type' => 'varchar', 'length' => 1024, 'not null' => TRUE, 'default' => "''", 'sortable' => TRUE),
         'title' => array('type' => 'varchar', 'length' => 1024, 'not null' => TRUE, 'default' => "''", 'sortable' => TRUE),
         'attributes' => array('type' => 'mediumtext', 'not null' => FALSE),
+        // changes to link_field_settings ($op == 'database columns')
+        'date' => array('type' => 'varchar', 'length' => 255, 'not null' => TRUE, 'default' => "''"),
       );
 
     case 'filters':
@@ -402,6 +404,22 @@
     '#default_value' => ($item['url']) ? $item['url'] : $default_url,
     '#required' => ($delta == 0) ? ($field['required'] && empty($field['url'])) : FALSE,
   );
+  // changes to _link_widget_form
+  $form_item['date'] = array(
+    '#type' => 'date_popup',
+    '#date_type' => DATE_DATETIME,
+    '#date_format' => 'm/d/Y',
+    '#maxlength' => '255',
+    '#date_year_range' => '-12:0',
+    '#process' => array('date_popup_process' => array()),
+    // is there supposed to be something in the array ^^^
+    '#validate' => array('date_popup_validate' => array()),
+    // is there supposed to be something in the array ^^^
+   '#description' => NULL,
+    '#title' => ($delta == 0) ? t('Birthdate') : NULL,
+    '#required' => ($delta == 0) ? $field['required'] : FALSE,
+  );
+
   if ($field['title'] != 'value' && $field['title'] != 'none') {
     $default_title = "";
     if (isset($field['widget']['default_value'][$delta]['title'])) {
@@ -437,6 +455,12 @@
   }
   // Trim whitespace from URL.
   $item['url'] = trim($item['url']);
+  // my attempt to process? found in _link_widget_process - gives me a fatal error
+  //Fatal error: Cannot use string offset as an array 
+  // in /var/www/clubs/sites/all/modules/date/date_popup/date_popup.module 
+  // on line 177 - if I uncomment the next line....
+  //$item['date'] = date_popup_process($item['date']);
+
   // Serialize the attributes array.
   $item['attributes'] = serialize($item['attributes']);
 
@@ -449,6 +473,10 @@
 }
 
 function _link_widget_validate(&$item, $delta, $field, $node, &$optional_field_found) {
+  // obviously in _link_wigdet_validate - my attempt to validate ?
+  // uncommenting the next line gives me a fatal error
+  // - out of memory (at 128MB for apache)
+  //$field['date'] = date_popup_validate($field['date']);
   if ($item['url'] && !(isset($field['widget']['default_value'][$delta]['url']) && $item['url'] == $field['widget']['default_value'][$delta]['url'] && !$field['required'])) {
     // Validate the link.
     if (link_validate_url(trim($item['url'])) == FALSE) {
@@ -532,6 +560,9 @@
     $output .= '<div class="link-field-title link-field-column">' . drupal_render($element['title']) . '</div>';
   }
   $output .= '<div class="link-field-url' . ($element['title'] ? ' link-field-column' : '') . '">' . drupal_render($element['url']) . '</div>';
+  // changes to theme_link_widget_form_row - adds the field to the form nicely (css can be used then to place it correctly)
+  $output .= '<div class="link-field-date' . ($element['title'] ? ' link-field-column' : '') . '">' . drupal_render($element['date']) . '</div>';
+
   $output .= '</div>';
   if ($element['attributes']) {
     $output .= '<div class="link-attributes">' . drupal_render($element['attributes']) . '</div>';
@@ -582,7 +613,9 @@
   }
 
   if ($formatter == 'plain') {
-    return empty($item['url']) ? check_plain($item['title']) : check_plain(link_cleanup_url($item['url']));
+    //return empty($item['url']) ? check_plain($item['title']) : check_plain(link_cleanup_url($item['url']));
+    // changes to link_field_formatter - not sure what would give me a date in the same format I saved it in (m/d/y)....
+    return empty($item['url']) ? check_plain($item['title'] . ' ' . $item['date']) : check_plain(link_cleanup_url($item['url']) . ' ' . $item['date']);
   }
 
   // Replace URL tokens.
@@ -641,14 +674,17 @@
   // Give the link the title 'Link'.
   if ($formatter == 'short') {
     $output = l(t('Link'), $url, $attributes, $query, $fragment);
+    $output .= ' ' . $item['date'];
   }
   // Build the link using the widget label.
   elseif ($formatter == 'label') {
     $output = l(t($field['widget']['label']), $url, $attributes, $query, $fragment);
+    $output .= ' ' . $item['date'];
   }
   // Build the link using the URL as title
   elseif ($formatter == 'url') {
     $output = l($display_url, $url, $attributes, $query, $fragment);
+    $output .= ' ' . $item['date'];
   }
   // Build the link using the widget label as separate title.
   elseif ($formatter == 'separate') {
@@ -667,14 +703,17 @@
     $title = _link_field_formatter_title($field, $item, $node);
     if (empty($url) && !empty($title)) {
       $output = check_plain($title);
+      $output .= ' ' . $item['date'];
     }
     else {
       $output = l($title, $url, $attributes, $query, $fragment, FALSE, $item['html']);
+      $output .= ' ' . $item['date'];
     }
   }
   // Build the link with the URL or email address as the title (max 80 characters).
   else {
     $output = l($display_url, $url, $attributes, $query, $fragment);
+    $output .= ' ' . $item['date'];
   }
   return $output;
 }
