Make WordPress Core


Ignore:
Timestamp:
10/17/2008 08:39:56 PM (18 years ago)
Author:
ryan
Message:

get_search_form from technosailor. fixes #7910

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/widgets.php

    r9219 r9234  
    764764function wp_widget_search($args) {
    765765    extract($args);
    766     $searchform_template = get_template_directory() . '/searchform.php';
    767 
    768766    echo $before_widget;
    769767
    770768    // Use current theme search form if it exists
    771     if ( file_exists($searchform_template) ) {
    772         include_once($searchform_template);
    773     } else { ?>
    774         <form id="searchform" method="get" action="<?php bloginfo('url'); ?>/"><div>
    775             <label class="hidden" for="s"><?php _e('Search for:'); ?></label>
    776             <input type="text" name="s" id="s" size="15" value="<?php the_search_query(); ?>" />
    777             <input type="submit" value="<?php echo attribute_escape(__('Search')); ?>" />
    778         </div></form>
    779     <?php }
    780 
     769    get_search_form();
     770   
    781771    echo $after_widget;
    782772}
Note: See TracChangeset for help on using the changeset viewer.