diff --git a/imagecrop.admin.inc b/imagecrop.admin.inc
index 3e2931a..01bf1f1 100755
--- a/imagecrop.admin.inc
+++ b/imagecrop.admin.inc
@@ -17,6 +17,11 @@ function imagecrop_settings() {
   if (module_exists('image')) {
     $options_modules['image'] = t('Hook into image module');
   }
+  // hook into taxonomy_image module
+  if (module_exists('taxonomy_image')) {
+    $options_modules['taxonomy_image'] = t('Hook into taxonomy image module');
+  }
+
 
   if (variable_get('user_pictures', 0)) {
     $options_modules['profile_picture'] = t('Hook into profile picture');
diff --git a/imagecrop.module b/imagecrop.module
index 1f1192e..3b52ac0 100755
--- a/imagecrop.module
+++ b/imagecrop.module
@@ -137,7 +137,7 @@ function imagecrop_cron() {
    * Deleted all records from deleted presets
    */
   $presets = return_presets();
-  if (!isset($presets['tabs'])) {
+   if (!isset($presets['tabs'])) {
     return;
   }
 
@@ -338,7 +338,7 @@ function imagecrop_process_cck_field($element) {
 function imagecrop_form_alter(&$form, $form_state, $form_id) {
 
   // No need to do checks on forms, other then node form.
-  if ($form['#id'] != 'node-form' && $form_id != '_node_images_edit_page' && $form_id != 'user_profile_form') {
+  if ($form['#id'] != 'node-form' && $form_id != '_node_images_edit_page' && $form_id != 'user_profile_form' && $form_id != 'taxonomy_form_term') {
     return;
   }
 
@@ -393,7 +393,10 @@ function imagecrop_form_alter(&$form, $form_state, $form_id) {
   elseif ($form_id == 'user_profile_form' && isset($form['picture']['current_picture']) && in_array('profile_picture', $hooks)) {
     $form['picture']['current_picture']['#value'] .= imagecrop_linkitem($form['_account']['#value']->uid, 'user');
   }
-
+  // hook into taxonomy image module
+  elseif ($form_id == 'taxonomy_form_term' && isset($form['taxonomy_image']['current_image']['image']['#value']) && in_array('taxonomy_image', $hooks)) {
+    $form['taxonomy_image']['current_image']['taxonomy_image_current_image_delete']['#prefix'] .= imagecrop_linkitem($form['tid']['#value'], 'taxonomy_image');
+  }
 }
 
 /**
@@ -674,11 +677,11 @@ function create_image_object($fid, $presetname, $module = '', $cutoff = FALSE) {
       $file->preset_height = $crop_height;
       $reference = ($module == 'node_images' || $module == 'user') ? $module : 'files';
       $firstscale = FALSE;
-
       $row = db_fetch_object(db_query(
         "SELECT xoffset, yoffset, width, height, scale
             FROM {imagecrop} ic
          WHERE ic.fid = %d AND ic.presetname = '%s' AND ic.reference = '%s'", $fid, $preset['presetname'], $reference));
+     // var_dump($row);
       if (!empty($row)) {
         $file->xoffset = $row->xoffset+$file->initial_xoffset;
         $file->yoffset = $row->yoffset+$file->initial_xoffset;
@@ -690,10 +693,8 @@ function create_image_object($fid, $presetname, $module = '', $cutoff = FALSE) {
         $file->scale = $row->scale;
         $firstscale = TRUE;
       }
-
       // resizable or not
       $file->resizable = $resizable;
-
 /*
       // start with original image size for upcoming actions.
       $src = $file->filepath;
@@ -778,6 +779,18 @@ function _imagecrop_file_load($fid, $module) {
     }
 
   }
+  elseif ($module == 'taxonomy_image') {
+
+    $filepath = db_result(db_query('SELECT path FROM {term_image} WHERE tid = %d', $fid));
+    if ($filepath) {
+        $file_directory = variable_get('file_directory_path', 'sites/default/files');
+        $file_directory .= '/'. variable_get('taxonomy_image_path', '');
+      $file = new stdClass();
+      $file->filepath = $file_directory . '/'. $filepath;
+      $file->filemime = file_get_mimetype($filepath);
+    }
+
+  }
 
   if ($file) {
 
diff --git a/imagecrop_actions.inc b/imagecrop_actions.inc
index 3535ef7..f6863f2 100755
--- a/imagecrop_actions.inc
+++ b/imagecrop_actions.inc
@@ -75,7 +75,6 @@ function imagecrop_javascript_form($data) {
  * Reset already cropped images to new width or height, when asked.
  */
 function imagecrop_javascript_submit($form, $form_state) {
-
   if ($form_state['values']['reset-crops'] === 1) {
     $preset_name = db_result(db_query('SELECT presetname FROM {imagecache_preset} WHERE presetid = %d', $form_state['values']['presetid']));
     if ($preset_name) {
@@ -197,6 +196,24 @@ function imagecrop_javascript_image(&$image, $data) {
       }
 
     }
+    if (!$row && in_array('taxonomy_image', $hooks)) {
+
+      $is_taxonomy_image = imagecrop_match_requested_file_directory($image->source, variable_get('taxonomy_image_path', 'category_pictures'));
+      if ($is_taxonomy_image) {
+
+        $file_directory = variable_get('file_directory_path', 'sites/default/files');
+        $file_directory .= '/'. variable_get('taxonomy_image_path', '');
+
+        $source = str_replace($file_directory .'/', '', $image->source);
+        $row = db_fetch_object(db_query("
+          SELECT xoffset, yoffset, width, height, scale
+            FROM {imagecrop} ic
+            INNER JOIN {term_image} t on t.tid = ic.fid
+          WHERE t.path = '%s' AND ic.presetname = '%s' " //AND reference = 'taxonomy_image'"
+          , $source, $presetname));
+      }
+
+    }
 
     // support for node images (this sucks in a way, because images are not stored in the files table)
     if (!$row && module_exists('node_images')) {
