allow_subdirectory_install

Definition:
function allow_subdirectory_install() {}

Allow subdirectory install

Return values

returns:Whether subdirectory install is allowed

Defined filters

  • allow_subdirectory_install
    apply_filters( 'allow_subdirectory_install', false )

Source code

function allow_subdirectory_install() {

	global $wpdb;

	if ( apply_filters( 'allow_subdirectory_install', false ) )

		return true;



	if ( defined( 'ALLOW_SUBDIRECTORY_INSTALL' ) && ALLOW_SUBDIRECTORY_INSTALL )

		return true;



	$post = $wpdb->get_row( "SELECT ID FROM $wpdb->posts WHERE post_date < DATE_SUB(NOW(), INTERVAL 1 MONTH) AND post_status = 'publish'" );

	if ( empty( $post ) )

		return true;



	return false;

}

527

No comments yet... Be the first to leave a reply!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: