diff --git a/drupal_jeditable.js b/drupal_jeditable.js
index f8c1a40..5fae824 100644
--- a/drupal_jeditable.js
+++ b/drupal_jeditable.js
@@ -1,22 +1,26 @@
-Drupal.behaviors.jeditable = function(context) {
-  $('.jeditable-textfield').editable('/jeditable/ajax/save', {
-    indicator : 'Saving...',
-    tooltip   : 'Click to edit...',
-    cancel    : 'Cancel',
-    submit    : 'Save',
-    style     : 'display: inline; min-width: 100px;'
-  });
-  $('.jeditable-textarea').editable('/jeditable/ajax/save', { 
-    type      : 'textarea',
-    cancel    : 'Cancel',
-    submit    : 'OK',
-    indicator : 'Saving...',
-    tooltip   : 'Click to edit...'
-  });
-  $('.jeditable-select').editable('/jeditable/ajax/save', { 
-     loadurl  : '/jeditable/ajax/load',
-     type     : 'select',
-     submit   : 'OK',
-     style    : 'display: inline'
-  });
-}
+(function ($) {
+  Drupal.behaviors.jeditable = {
+    attach: function(context) {
+      $('.jeditable-textfield', context).editable('/jeditable/ajax/save', {
+        indicator : 'Saving...',
+        tooltip   : 'Click to edit...',
+        cancel    : 'Cancel',
+        submit    : 'Save',
+        style     : 'display: inline; min-width: 100px;'
+      });
+      $('.jeditable-textarea', context).editable('/jeditable/ajax/save', { 
+        type      : 'textarea',
+        cancel    : 'Cancel',
+        submit    : 'OK',
+        indicator : 'Saving...',
+        tooltip   : 'Click to edit...'
+      });
+      $('.jeditable-select', context).editable('/jeditable/ajax/save', { 
+        loadurl  : '/jeditable/ajax/load',
+        type     : 'select',
+        submit   : 'OK',
+        style    : 'display: inline'
+      });
+    }
+  };
+})(jQuery);
diff --git a/jeditable.info b/jeditable.info
index a0d90c4..ec6bf76 100644
--- a/jeditable.info
+++ b/jeditable.info
@@ -1,6 +1,6 @@
 name = jEditable
-description = Provides methods and CCK Formatters for using the jEditable edit-in-place plugin
-dependencies[] = content
+description = Provides methods and field formatters for using the jEditable edit-in-place plugin
+dependencies[] = field
 package = User Interface
-core = 6.x
+core = 7.x
 
diff --git a/jeditable.module b/jeditable.module
index 82ae3e3..e885788 100644
--- a/jeditable.module
+++ b/jeditable.module
@@ -5,7 +5,7 @@
  */
 
 /**
- * Implementation of hook_menu()
+ * Implements hook_menu().
  */
 function jeditable_menu() {
   $items['jeditable/ajax/save'] = array(
@@ -42,67 +42,83 @@ function jeditable_admin_settings() {
 }
 
 /**
- * Implementation of hook_perm()
+ * Implements hook_permission().
  */
-function jeditable_perm() {
-  return array('use jeditable');
-}
-
-/**
- * Implementation of hook_init().
- */
-function jeditable_init() {
-  if(user_access('use jeditable')) {
-    drupal_add_js(drupal_get_path('module', 'jeditable') .'/jquery.jeditable.mini.js', 'module');
-    drupal_add_js(drupal_get_path('module', 'jeditable') .'/drupal_jeditable.js', 'module');
-    drupal_add_css(drupal_get_path('module', 'jeditable') .'/jeditable.css', 'theme');
-  }
+function jeditable_permission() {
+  return array(
+    'use jeditable' => array(
+      'title' => t('Use jEditable'),
+      'description' => t('Use jEditable to edit fields in place.'),
+    ),
+  );
 }
 
 /**
- * Implementation of hook_field_formatter_info(),.
+ * Implements hook_field_formatter_info(),.
  */
 function jeditable_field_formatter_info() {
   return array(
     'jeditable_textfield' => array(
       'label' => t('jEditable Textfield'),
       'field types' => array('text', 'number_integer', 'number_decimal', 'number_float'),
-      'multiple values' => CONTENT_HANDLE_MODULE,
     ),
     'jeditable_textarea' => array(
       'label' => t('jEditable Textarea'),
-      'field types' => array('text'),
-      'multiple values' => CONTENT_HANDLE_MODULE,
+      'field types' => array('text_long'),
     ),
     'jeditable_nodereference' => array(
       'label' => t('jEditable Nodereference'),
       'field types' => array('nodereference'),
-      'multiple values' => CONTENT_HANDLE_MODULE,
     ),
     'jeditable_datetime' => array(
       'label' => t('jEditable Datetime picker'),
       'field types' => array('datetime'),
-      'multiple values' => CONTENT_HANDLE_MODULE,
     ),
   );
 }
 
 /**
- * Implementation of hook_theme().
+ * Implements hook_field_formatter_view().
+ */
+function jeditable_field_formatter_view($entity_type, $entity, $field, $instance, $langcode, $items, $display) {
+  $path = drupal_get_path('module', 'jeditable');
+  $elements = array();
+  foreach ($items as $delta => $item) {
+    $elements[$delta] = array(
+      '#markup' => theme('jeditable_formatter_'. $display['type'], array('element' => $item, 'field' => $instance, 'entity' => $entity, 'entity_type' => $entity_type)),
+    );
+
+    if (user_access('use jeditable')) {
+      $elements[$delta]['#attached'] = array(
+        'js' => array(
+          $path . '/jquery.jeditable.mini.js',
+          $path . '/drupal_jeditable.js',
+        ),
+        'css' => array(
+          $path . '/jeditable.css',
+        ),
+      );
+    }
+  }
+  return $elements;
+}
+
+/**
+ * Implements hook_theme().
  */
 function jeditable_theme() {
   return array(
     'jeditable_formatter_jeditable_textfield' => array(
-      'arguments' => array('element' => NULL),
+      'arguments' => array('element' => NULL, 'field' => NULL, 'entity' => NULL, 'entity_type' => NULL),
     ),
     'jeditable_formatter_jeditable_textarea' => array(
-      'arguments' => array('element' => NULL),
+      'arguments' => array('element' => NULL, 'field' => NULL, 'entity' => NULL, 'entity_type' => NULL),
     ),
     'jeditable_formatter_jeditable_datetime' => array(
-      'arguments' => array('element' => NULL),
+      'arguments' => array('element' => NULL, 'field' => NULL, 'entity' => NULL, 'entity_type' => NULL),
     ),
     'jeditable_formatter_jeditable_nodereference' => array(
-      'arguments' => array('element' => NULL),
+      'arguments' => array('element' => NULL, 'field' => NULL, 'entity' => NULL, 'entity_type' => NULL),
     ),
     'jeditable_workflow' => array(
       'arguments' => array('node' => NULL),
@@ -111,25 +127,72 @@ function jeditable_theme() {
 }
 
 /**
- * Theme a CCK text field as a jeditable textfield.
+ * Returns the id fo
+
+/**
+ * Theme a text field as a jeditable textfield.
  *
  * @ingroup themeable
  */
-function theme_jeditable_formatter_jeditable_textfield($element) {
-  $id = $element['#node']->nid;
-  $field = $element['#field_name'];
-  return '<span id="cck-'. $id .'-'. $field .'" class="jeditable-textfield">'. $element[0]['#item']['value'] .'</span>';
+function theme_jeditable_formatter_jeditable_textfield($variables) {
+  $element     = $variables['element'];
+  $field       = $variables['field'];
+  $entity      = $variables['entity'];
+  $entity_type = $variables['entity_type'];
+
+  switch ($entity_type) {
+    case 'node':
+      // Check user's access to editing this node.
+      if (!node_access('update', $entity)) {
+        return $element['value'];
+      }
+
+      $id = $entity->nid;
+      break;
+
+    case 'user':
+      // Check user's access to editing this user.
+      if (!user_edit_access($entity)) {
+        return $element['value'];
+      }
+      $id = $entity->uid;
+      break;
+  }
+
+  return '<span id="' . $entity_type . '-' . $id . '-' . $field['field_name'] . '" class="jeditable jeditable-textfield">' . $element['value'] . '</span>';
 }
 
 /**
- * Theme a CCK text field as a jeditable textarea.
+ * Theme a textarea field as a jeditable textarea.
  *
  * @ingroup themeable
  */
-function theme_jeditable_formatter_jeditable_textarea($element) {
-  $id = $element['#node']->nid;
-  $field = $element['#field_name'];
-  return '<span id="cck-'. $id .'-'. $field .'" class="jeditable-textarea">'. $element[0]['#item']['value'] .'</span>';
+function theme_jeditable_formatter_jeditable_textarea($variables) {
+  $element     = $variables['element'];
+  $field       = $variables['field'];
+  $entity      = $variables['entity'];
+  $entity_type = $variables['entity_type'];
+
+  switch ($entity_type) {
+    case 'node':
+      // Check user's access to editing this node.
+      if (!node_access('update', $entity)) {
+        return $element['value'];
+      }
+
+      $id = $entity->nid;
+      break;
+
+    case 'user':
+      // Check user's access to editing this user.
+      if (!user_edit_access($entity)) {
+        return $element['value'];
+      }
+      $id = $entity->uid;
+      break;
+  }
+
+  return '<span id="' . $entity_type . '-' . $id . '-' . $field['field_name'] . '" class="jeditable jeditable-textarea">' . $element['value'] . '</span>';
 }
 
 /**
@@ -141,7 +204,7 @@ function theme_jeditable_formatter_jeditable_nodereference($element) {
   $id = $element['#node']->nid;
   $field = $element['#field_name'];
   $node = node_load($element[0]['#item']['nid']);
-  return '<span id="cck-'. $id .'-'. $field .'" class="jeditable-select">'. $node->title .'</span>';
+  return '<span id="cck-' . $id . '-' . $field . '" class="jeditable-select">' . $node->title . '</span>';
 }
 
 /**
@@ -152,7 +215,7 @@ function theme_jeditable_formatter_jeditable_nodereference($element) {
 function theme_jeditable_formatter_jeditable_datetime($element) {
   $id = $element['#node']->nid;
   $field = $element['#field_name'];
-  return '<span id="cck-'. $id .'-'. $field .'" class="jeditable-textfield edit-datetime">'. $element[0]['#item']['value'] .'</span>';
+  return '<span id="cck-' . $id . '-' . $field . '" class="jeditable-textfield edit-datetime">' . $element[0]['#item']['value'] . '</span>';
 }
 
 /**
@@ -170,7 +233,7 @@ function theme_jeditable_workflow($node) {
   $field = $node->_workflow ? $node->_workflow : $node->workflow; // named differently depending on how far the node has loaded
   
   $state = workflow_get_state_name($field);
-  return '<span id="workflow-'. $id .'-'. $field .'" class="jeditable-select">'. $state .'</span>';
+  return '<span id="workflow-' . $id . '-' . $field . '" class="jeditable-select">' . $state . '</span>';
 }
 
 /**
@@ -188,18 +251,29 @@ function _jeditable_ajax_save() {
       if(!node_access('update', $node)) { // check to see that current user has update permissions on the node
         $value = 'access denied'; // this is the value that will be returned, but no updates made
       } else {
-        $node->{$field_name} = $value;
+        $node->{$field_name}[$node->language][0] = $value;
         $node->revision = variable_get('jeditable_create_new_revisions', false);
         node_save($node);
       }
       break;
+
+    case 'user':
+      $user = user_load($id);
+      if(!user_edit_access($user)) { // check to see that current user has update permissions on the user
+        $value = 'access denied'; // this is the value that will be returned, but no updates made
+      } else {
+        $user->{$field_name}[$user->language][0]['value'] = $value;
+        user_save($user);
+      }
+      break;
+
     case 'cck':
       $node = node_load($id);
       if(!node_access('update', $node)) { // check to see that current user has update permissions on the node
         $value = 'access denied'; // this is the value that will be returned, but no updates made
       } else {
         $field = content_fields($field_name, $node->type);
-        
+
         // assign nid if nodereference, format date if date, otherwise just assign value
         if($field['type'] == 'nodereference') {
           $node->{$field_name}[0]['nid'] = $value;
@@ -216,12 +290,7 @@ function _jeditable_ajax_save() {
         node_save($node);
       }
       break;
-    case 'user':
-      /** should be implemented if user reference field is implemented **/
-      $user = user_load(array('uid' => $id));
-      $user->{$field_name} = $value;
-      user_save($user);
-      break;
+
     case 'workflow':
       $node = node_load($id);
       $value = _jeditable_workflow_save($node, $value);
@@ -322,7 +391,7 @@ function _jeditable_workflow_save($node, $sid) {
     return workflow_get_state_name($sid);
   } else {
     // here's where we do the actual transition. It will fail if user does not have appropriate permissions.
-    $new_sid = workflow_execute_transition($node, $sid, 'set using jeditable at '. referer_uri());
+    $new_sid = workflow_execute_transition($node, $sid, 'set using jeditable at ' . $_SERVER['HTTP_REFERER']);
   }
   
   if(empty($new_sid)) {
