diff --git a/interface/web/monitor/dataloghistory_view.php b/interface/web/monitor/dataloghistory_view.php
index 5c2043d63f8eff7cd106e56bd00dac68cfb73320..2e3d3bd2f9fcb70bd7b84537d2b4dc2b265fb2b4 100644
--- a/interface/web/monitor/dataloghistory_view.php
+++ b/interface/web/monitor/dataloghistory_view.php
@@ -56,13 +56,26 @@ $out['timestamp'] = date($app->lng('conf_format_datetime'), $record['tstamp']);
 $out['table'] = $record['dbtable'];
 list($key, $value) = explode(':', $record['dbidx']);
 if (!empty($value)) {
-       if ($record['action'] == 'd') {
-               // No link for deleted content.
-               $out['table_id'] = $record['dbidx'];
-       } else {
-               // TODO link per content type
-               $out['table_id'] = '<a href="#" data-load-content="mail/mail_user_edit.php?id=' . $value .'" data-toggle="tooltip" data-placement="bottom" title="" data-original-title="link">'.$record['dbidx'].'</a>';
-       }
+  if ($record['action'] == 'd') {
+    // No link for deleted content.
+    $out['table_id'] = $record['dbidx'];
+  } else {
+    switch ($out['table']) {
+      case 'mail_forwarding':
+        $file = 'mail/mail_forward_edit.php';
+        break;
+      case 'mail_user':
+        $file = 'mail/mail_user_edit.php';
+        break;
+      case 'mail_domain':
+        $file = 'mail/mail_domain_edit.php';
+        break;
+      default:
+        $file = '';
+    }
+    // TODO link per content type
+    $out['table_id'] = '<a href="#" data-load-content="' . $file . '?id=' . $value .'" data-toggle="tooltip" data-placement="bottom" title="" data-original-title="link">'.$record['dbidx'] . $file .'</a>';
+  }
 }
 
 $out['action_char'] = $record['action'];