function wpsolr_after_setup_theme()
{
    // Load active extensions
    WpSolrExtensions::load();
    /*
     * Load WPSOLR text domain to the Wordpress languages plugin directory (WP_LANG_DIR/plugins)
     * Copy your .mo files there
     * Example: /htdocs/wp-includes/languages/plugins/wpsolr-fr_FR.mo or /htdocs/wp-content/languages/plugins/wpsolr-fr_FR.mo
     * You can find our template file in this plugin's /languages/wpsolr.pot file
     */
    load_plugin_textdomain('wpsolr', false, false);
    /**
     * Load dynamic string translations
     */
    if (is_admin()) {
        // Load all string translations for all data managed by all extensions
        WpSolrExtensions::extract_strings_to_translate_for_all_extensions();
    }
}
<?php

include dirname(__FILE__) . '/classes/solr/wpsolr-index-solr-client.php';
include dirname(__FILE__) . '/classes/solr/wpsolr-search-solr-client.php';
include dirname(__FILE__) . '/classes/ui/WPSOLR_Data_facets.php';
// Load localization class
WpSolrExtensions::require_once_wpsolr_extension(WpSolrExtensions::OPTION_LOCALIZATION, true);
WpSolrExtensions::load();
function solr_format_date($thedate)
{
    $datere = '/(\\d{4}-\\d{2}-\\d{2})\\s(\\d{2}:\\d{2}:\\d{2})/';
    $replstr = '${1}T${2}Z';
    return preg_replace($datere, $replstr, $thedate);
}
function fun_search_indexed_data()
{
    $ad_url = admin_url();
    // Retrieve search form page url
    $get_page_info = WPSolrSearchSolrClient::get_search_page();
    $url = get_permalink($get_page_info->ID);
    // Filter the search page url. Used for multi-language search forms.
    $url = apply_filters(WpSolrFilters::WPSOLR_FILTER_SEARCH_PAGE_URL, $url, $get_page_info->ID);
    // Load localization options
    $localization_options = OptionLocalization::get_options();
    $wdm_typehead_request_handler = 'wdm_return_solr_rows';
    echo "<div class='cls_search' style='width:100%'> <form action='{$url}' method='get'  class='search-frm' >";
    echo '<input type="hidden" value="' . $wdm_typehead_request_handler . '" id="path_to_fold">';
    echo '<input type="hidden" value="' . $ad_url . '" id="path_to_admin">';
    echo '<input type="hidden" value="' . WPSOLR_Global::getQuery()->get_wpsolr_query() . '" id="search_opt">';
    $ajax_nonce = wp_create_nonce("nonce_for_autocomplete");
    echo $form = '