require_once $require_prefix . "footer.php"; require_once $require_prefix . "dsidxpress_seo.php"; require_once $require_prefix . "autocomplete.php"; require_once $require_prefix . "idx-listings-pages.php"; if (is_admin()) { // this is needed specifically for development as PHP seems to choke when 1) loading this in admin, 2) using windows, 3) using directory junctions include_once str_replace("\\", "/", WP_PLUGIN_DIR) . "/dsidxpress/admin.php"; } else { require_once $require_prefix . "client.php"; require_once $require_prefix . "shortcodes.php"; } if (defined('DS_API')) { dsSearchAgent_ApiRequest::$ApiEndPoint = DS_API; } else { define('DS_API', 'http://api-c.idx.diversesolutions.com/api/'); dsSearchAgent_ApiRequest::$ApiEndPoint = DS_API; } register_activation_hook(__FILE__, "dsidxpress_FlushRewriteRules"); add_action("widgets_init", "dsidxpress_InitWidgets"); // not in a static class to prevent PHP < 5 from failing when including and interpreting this particular file function dsidxpress_DisplayVersionWarnings() { global $wp_version; $currentVersionPhp = phpversion(); $currentVersionWordPress = $wp_version; $minVersionPhp = DSIDXPRESS_MIN_VERSION_PHP; $minVersionWordPress = DSIDXPRESS_MIN_VERSION_WORDPRESS; echo <<<HTML \t\t<div class="error"> \t\t\tIn order to use the dsIDXpress plugin, your web server needs to be running at least PHP {$minVersionPhp} and WordPress {$minVersionWordPress}. \t\t\tYou're currently using PHP {$currentVersionPhp} and WordPress {$currentVersionWordPress}. Please consider upgrading.