Index: views_handler_field.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/handlers/views_handler_field.inc,v
retrieving revision 1.14
diff -u -r1.14 views_handler_field.inc
--- views_handler_field.inc	8 Apr 2009 05:23:56 -0000	1.14
+++ views_handler_field.inc	26 Apr 2009 04:04:41 -0000
@@ -147,6 +147,7 @@
         'alter_text' => array('default' => FALSE),
         'text' => array('default' => '', 'translatable' => TRUE),
         'make_link' => array('default' => FALSE),
+        'blank' => array('defautl' => FALSE),
         'path' => array('default' => '', 'translatable' => TRUE),
         'alt' => array('default' => '', 'translatable' => TRUE),
         'prefix' => array('default' => '', 'translatable' => TRUE),
@@ -207,6 +208,18 @@
         '#description' => t('If checked, this field will be made into a link. The destination must be given below.'),
         '#default_value' => $this->options['alter']['make_link'],
       );
+
+      $form['alter']['blank'] = array(
+        '#type' => 'checkbox',
+        '#title' => t('Open link in a new window'),
+        '#description' => t('If checked, the link will open in a new window.'),
+        '#default_value' => $this->options['alter']['blank'],
+        '#process' => array('views_process_dependency'),
+        '#dependency' => array(
+          'edit-options-alter-make-link' => array(1)
+        ),
+      );
+
       $form['alter']['path'] = array(
         '#title' => t('Link path'),
         '#type' => 'textfield',
@@ -486,6 +499,8 @@
     $alt = $this->options['alter']['alt'];
     $alt = strtr($alt, $tokens);
 
+    $blank = $this->options['alter']['blank'];
+
     $value = '';
 
     if (!empty($this->options['alter']['prefix'])) {
@@ -501,6 +516,10 @@
       $options['attributes']['alt'] = $alt;
     }
 
+    if ($blank) {
+      $options['attributes']['target'] = '_blank';
+    }
+
     // These can only be set internally at this time.
     if (isset($this->options['alter']['query'])) {
       $options['query'] = $this->options['alter']['query'];
