示例#1
0
 function op_include_files()
 {
     require_once OP_FUNC . 'widgets.php';
     require_once OP_FUNC . 'options.php';
     require_once OP_FUNC . 'page_options.php';
     require_once OP_FUNC . 'general.php';
     require_once OP_FUNC . 'scripts.php';
     require_once OP_FUNC . 'assets.php';
     require_once OP_FUNC . 'fonts.php';
     require_once OP_FUNC . 'sl_api.php';
     op_textdomain();
     require_once OP_FUNC . 'templates.php';
     _op_assets();
     add_theme_support('automatic-feed-links');
     add_theme_support('post-thumbnails');
     if (is_admin()) {
         require_once OP_FUNC . 'admin.php';
         require_once OP_ADMIN . 'init.php';
     } else {
         op_register_scripts();
         do_action('op_pre_template_include');
         require_once ABSPATH . 'wp-admin/includes/plugin.php';
         /*
          * DAP
          */
         if (is_plugin_active('DAP-WP-LiveLinks/DAP-WP-LiveLinks.php')) {
             add_filter('op_check_page_availability', 'dap_allowed_page');
         }
         /*
          * Fast Member
          */
         if (is_plugin_active('fastmember/fastmember.php')) {
             add_filter('op_check_page_availability', 'fast_member_allowed_page');
         }
         /*
          * iMember
          */
         if (class_exists('infusionWP')) {
             add_filter('op_check_page_availability', 'imember_allowed_page');
         }
         add_filter('template_include', 'op_template_include');
         do_action('op_setup');
         //op_localize_script('front');
     }
 }
示例#2
0
 function op_include_files()
 {
     require_once OP_FUNC . 'widgets.php';
     require_once OP_FUNC . 'options.php';
     require_once OP_FUNC . 'page_options.php';
     require_once OP_FUNC . 'general.php';
     require_once OP_FUNC . 'scripts.php';
     require_once OP_FUNC . 'assets.php';
     require_once OP_FUNC . 'fonts.php';
     require_once OP_FUNC . 'sl_api.php';
     op_textdomain();
     require_once OP_FUNC . 'templates.php';
     _op_assets();
     add_theme_support('automatic-feed-links');
     add_theme_support('post-thumbnails');
     if (is_admin()) {
         require_once OP_FUNC . 'admin.php';
         require_once OP_ADMIN . 'init.php';
     } else {
         op_register_scripts();
         do_action('op_pre_tempate_include');
         add_filter('template_include', 'op_template_include');
         do_action('op_setup');
     }
 }