Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: install_themes_tabs

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

Line Code
109       * Filter the tabs shown on the Add Themes screen.
110       *
111       * This filter is for backwards compatibility only, for the suppression
112       * of the upload tab.
113       *
114       * @since 2.8.0
115       *
116       * @param array $tabs The tabs shown on the Add Themes screen. Default is 'upload'.
117       */
118      $tabs = apply_filters( 'install_themes_tabs', array( 'upload' => __( 'Upload Theme' ) ) );
119      if ( ! empty( $tabs['upload'] ) && current_user_can( 'upload_themes' ) ) {
120           echo ' <a href="#" class="upload add-new-h2">' . __( 'Upload Theme' ) . '</a>';
121           echo ' <a href="#" class="browse-themes add-new-h2">' . _x( 'Browse', 'themes' ) . '</a>';
122      }
123      ?></h2>
124
125      <div class="upload-theme">
126      <?php install_themes_upload(); ?>
127      </div>