Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: disable_captions

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

This hook occurs 2 times in this file.

Line Code
965
966           <span class="setting alt-text has-description">
967                <label for="embed-image-settings-alt-text" class="name"><?php _e( 'Alternative Text' ); ?></label>
968                <input type="text" id="embed-image-settings-alt-text" data-setting="alt" aria-describedby="alt-text-description" />
969           </span>
970           <p class="description" id="alt-text-description"><?php echo $alt_text_description; ?></p>
971
972           <?php
973           /** This filter is documented in wp-admin/includes/media.php */
974           if ( ! apply_filters( 'disable_captions', '' ) ) :
975                ?>
976                <span class="setting caption">
977                     <label for="embed-image-settings-caption" class="name"><?php _e( 'Caption' ); ?></label>
978                     <textarea id="embed-image-settings-caption" data-setting="caption" />
979                </span>
980           <?php endif; ?>
981
982           <fieldset class="setting-group">
983                <legend class="name"><?php _e( 'Align' ); ?></legend>
 
Line Code
1028                     <div class="column-settings">
1029                          <span class="setting alt-text has-description">
1030                               <label for="image-details-alt-text" class="name"><?php _e( 'Alternative Text' ); ?></label>
1031                               <input type="text" id="image-details-alt-text" data-setting="alt" value="{{ data.model.alt }}" aria-describedby="alt-text-description" />
1032                          </span>
1033                          <p class="description" id="alt-text-description"><?php echo $alt_text_description; ?></p>
1034
1035                          <?php
1036                          /** This filter is documented in wp-admin/includes/media.php */
1037                          if ( ! apply_filters( 'disable_captions', '' ) ) :
1038                               ?>
1039                               <span class="setting caption">
1040                                    <label for="image-details-caption" class="name"><?php _e( 'Caption' ); ?></label>
1041                                    <textarea id="image-details-caption" data-setting="caption">{{ data.model.caption }}</textarea>
1042                               </span>
1043                          <?php endif; ?>
1044
1045                          <h2><?php _e( 'Display Settings' ); ?></h2>
1046                          <fieldset class="setting-group">