Changeset 9597
- Timestamp:
- 03/17/2020 08:31:01 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support/searchform.php
r5163 r9597 17 17 <label for="s" class="screen-reader-text"><?php _ex( 'Search for:', 'label', 'wporg-forums' ); ?></label> 18 18 <?php 19 $tab = null; 19 20 if ( 'wporg_compat_before_single_view' === current_action() ) { 20 21 $placeholder = _x( 'Search this forum', 'placeholder', 'wporg-forums' ); 21 22 $project = wporg_support_get_compat_object(); 23 } elseif ( is_front_page() ) { 24 $placeholder = _x( 'Search documentation', 'placeholder', 'wporg-forums' ); 25 $project = null; 26 $tab = 'docs'; 22 27 } else { 23 28 $placeholder = _x( 'Search forums', 'placeholder', 'wporg-forums' ); … … 29 34 <input type="hidden" name="intext" value="<?php echo esc_attr( $project->prefixed_title ); ?>" /> 30 35 <?php endif; ?> 36 <?php if ( $tab ) : ?> 37 <input type="hidden" name="tab" value="<?php echo esc_attr( $tab ); ?>" /> 38 <?php endif; ?> 31 39 <button class="button button-primary button-search"><i class="dashicons dashicons-search"></i><span class="screen-reader-text"><?php _e( 'Search forums', 'wporg-forums' ); ?></span></button> 32 40 </form>
Note: See TracChangeset
for help on using the changeset viewer.