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
119       * Filter the tabs shown on the Add Themes screen.
120       *
121       * This filter is for backwards compatibility only, for the suppression
122       * of the upload tab.
123       *
124       * @since 2.8.0
125       *
126       * @param array $tabs The tabs shown on the Add Themes screen. Default is 'upload'.
127       */
128      $tabs = apply_filters( 'install_themes_tabs', array( 'upload' => __( 'Upload Theme' ) ) );
129      if ( ! empty( $tabs['upload'] ) && current_user_can( 'upload_themes' ) ) {
130           echo ' <a href="#" class="upload page-title-action">' . __( 'Upload Theme' ) . '</a>';
131           echo ' <a href="#" class="browse-themes page-title-action">' . _x( 'Browse', 'themes' ) . '</a>';
132      }
133      ?></h1>
134
135      <div class="upload-theme">
136      <?php install_themes_upload(); ?>
137      </div>