link_target_meta_box

Display form fields for changing link target.

Description

link_target_meta_box( (object) $link ); 

Parameters (1)

0. $link (object)
The link.

Usage

  1. if ( !function_exists( 'link_target_meta_box' ) ) { 
  2. require_once ABSPATH . '/wp-admin/includes/meta-boxes.php'; 
  3.  
  4. // The link. 
  5. $link = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = link_target_meta_box($link); 
  9.  

Defined (1)

The function is defined in the following location(s).

/wp-admin/includes/meta-boxes.php  
  1. function link_target_meta_box($link) { ?> 
  2. <fieldset><legend class="screen-reader-text"><span><?php _e('Target') ?></span></legend> 
  3. <p><label for="link_target_blank" class="selectit"> 
  4. <input id="link_target_blank" type="radio" name="link_target" value="_blank" <?php echo ( isset( $link->link_target ) && ($link->link_target == '_blank') ? 'checked="checked"' : ''); ?> /> 
  5. <?php _e('<code>_blank</code> — new window or tab.'); ?></label></p> 
  6. <p><label for="link_target_top" class="selectit"> 
  7. <input id="link_target_top" type="radio" name="link_target" value="_top" <?php echo ( isset( $link->link_target ) && ($link->link_target == '_top') ? 'checked="checked"' : ''); ?> /> 
  8. <?php _e('<code>_top</code> — current window or tab, with no frames.'); ?></label></p> 
  9. <p><label for="link_target_none" class="selectit"> 
  10. <input id="link_target_none" type="radio" name="link_target" value="" <?php echo ( isset( $link->link_target ) && ($link->link_target == '') ? 'checked="checked"' : ''); ?> /> 
  11. <?php _e('<code>_none</code> — same window or tab.'); ?></label></p> 
  12. </fieldset> 
  13. <p><?php _e('Choose the target frame for your link.'); ?></p> 
  14. <?php