--- quota_by_role.module
+++ quota_by_role.module
@@ -204,7 +204,15 @@ function quota_by_role_add_quota() {
       $first = true;
     }    
 
-    $img = '<a href="?delete='.$r->qid.'"><img src="/misc/watchdog-error.png" alt="'.t('delete quota').'" title="'.t('delete quota').'" height="18" width="18"></a>';
+    $img = l('<img src="' . base_path() . 'misc/watchdog-error.png" alt="'.t('delete quota').'" title="'.t('delete quota').'" height="18" width="18" />',
+      'admin/settings/quota_by_role',
+      array(
+        'query' => array(
+          'delete' => $r->qid
+          ),
+        'html' => TRUE, //to pass the '<img...' as is, and not passed to check_plain
+        )
+      );
     $rows[] = array($r->name, $r->limit_to, $content_type, t($per), $r->weight, $img);
   }
   // We add a hidden element to the form, in order to use the #suffix component to add a table
