LLMS_Site::is_clone()

Determine if this is a cloned site


Description Description

Compares the stored (and cleaned) llms_site_url against the WP site url.


Top ↑

Return Return

(boolean) Returns true if it's a cloned site (urls do not match) and false if it's not (urls DO match).


Top ↑

Source Source

File: includes/class.llms.site.php

	public static function is_clone() {

		$is_clone = defined( 'LLMS_SITE_IS_CLONE' ) ? LLMS_SITE_IS_CLONE : ( get_site_url() !== self::get_url() );

		/**
		 * Filters whether or not the site is a "cloned" site
		 *
		 * @since 3.0.0
		 *
		 * @param boolean $is_clone When `true` the site is considered a "clone", otherwise it is not.
		 */
		return apply_filters( 'llms_site_is_clone', $is_clone );

	}


Top ↑

Changelog Changelog

Changelog
Version Description
4.13.0 Add LLMS_SITE_IS_CLONE constant check.
3.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.