[ XREF Home ] [ Index ]

PHP Cross Reference of WordPress Trunk

Provided by Yoast

title

Body

[close]

/wp-includes/ -> ms-default-filters.php (source)

   1  <?php
   2  /**
   3   * Sets up the default filters and actions for Multisite.
   4   *
   5   * If you need to remove a default hook, this file will give you the priority
   6   * for which to use to remove the hook.
   7   *
   8   * Not all of the Multisite default hooks are found in ms-default-filters.php
   9   *
  10   * @package WordPress
  11   * @subpackage Multisite
  12   * @see default-filters.php
  13   * @since 3.0.0
  14   */
  15  
  16  // Users
  17  add_filter( 'wpmu_validate_user_signup', 'signup_nonce_check' );
  18  add_action( 'init', 'maybe_add_existing_user_to_blog' );
  19  add_action( 'wpmu_new_user', 'newuser_notify_siteadmin' );
  20  add_action( 'wpmu_activate_user', 'add_new_user_to_blog', 10, 3 );
  21  add_action( 'sanitize_user', 'strtolower' );
  22  
  23  // Blogs
  24  add_filter( 'wpmu_validate_blog_signup', 'signup_nonce_check' );
  25  add_action( 'wpmu_new_blog', 'wpmu_log_new_registrations', 10, 2 );
  26  add_action( 'wpmu_new_blog', 'newblog_notify_siteadmin', 10, 2 );
  27  
  28  // Register Nonce
  29  add_action( 'signup_hidden_fields', 'signup_nonce_fields' );
  30  
  31  // Template
  32  add_action( 'template_redirect', 'maybe_redirect_404' );
  33  add_filter( 'allowed_redirect_hosts', 'redirect_this_site' );
  34  
  35  // Administration
  36  add_filter( 'term_id_filter', 'global_terms', 10, 2 );
  37  add_action( 'publish_post', 'update_posts_count' );
  38  add_action( 'delete_post', 'wpmu_update_blogs_date' );
  39  add_action( 'private_to_published', 'wpmu_update_blogs_date' );
  40  add_action( 'publish_phone', 'wpmu_update_blogs_date' );
  41  add_action( 'publish_post', 'wpmu_update_blogs_date' );
  42  add_action( 'admin_init', 'wp_schedule_update_network_counts');
  43  add_action( 'update_network_counts', 'wp_update_network_counts');
  44  
  45  // Files
  46  add_filter( 'wp_upload_bits', 'upload_is_file_too_big' );
  47  add_filter( 'import_upload_size_limit', 'fix_import_form_size' );
  48  add_filter( 'upload_mimes', 'check_upload_mimes' );
  49  add_filter( 'upload_size_limit', 'upload_size_limit_filter' );
  50  
  51  // Mail
  52  add_action( 'phpmailer_init', 'fix_phpmailer_messageid' );
  53  
  54  // Disable somethings by default for multisite
  55  add_filter( 'enable_update_services_configuration', '__return_false' );
  56  if ( ! defined('POST_BY_EMAIL') || ! POST_BY_EMAIL ) // back compat constant.
  57      add_filter( 'enable_post_by_email_configuration', '__return_false' );
  58  if ( ! defined('EDIT_ANY_USER') || ! EDIT_ANY_USER ) // back compat constant.
  59      add_filter( 'enable_edit_any_user_configuration', '__return_false' );
  60  add_filter( 'force_filtered_html_on_import', '__return_true' );
  61  
  62  // WP_HOME and WP_SITEURL should not have any effect in MS
  63  remove_filter( 'option_siteurl', '_config_wp_siteurl' );
  64  remove_filter( 'option_home',    '_config_wp_home'    );
  65  
  66  ?>


Generated: Wed Jun 1 08:30:02 2011 Cross-referenced by PHPXref 0.7
Provided by Yoast and awesome WordPress Hosting