Current Path: > home > codekrsu > > ameliagraphics.com > wp-content > plugins > content-control > classes > > Plugin >
Operation : Linux premium131.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64 Software : Apache Server IP : 162.0.232.56 | Your IP: 216.73.216.111 Domains : 1034 Domain(s) Permission : [ 0755 ]
Name | Type | Size | Last Modified | Actions |
---|---|---|---|---|
Autoloader.php | File | 1732 bytes | December 08 2023 15:26:30. | |
Connect.php | File | 15298 bytes | December 08 2023 15:26:30. | |
Core.php | File | 11562 bytes | May 09 2025 02:30:24. | |
Install.php | File | 3128 bytes | September 21 2023 14:13:04. | |
License.php | File | 12404 bytes | December 08 2023 15:26:30. | |
Logging.php | File | 9538 bytes | December 08 2023 15:26:30. | |
Options.php | File | 5457 bytes | December 08 2023 15:26:30. | |
Prerequisites.php | File | 10409 bytes | September 21 2023 14:13:04. | |
Upgrader.php | File | 5813 bytes | May 09 2025 02:30:24. |
<?php /** * Plugin installer. * * @copyright (c) 2021, Code Atlantic LLC. * * @package ContentControl\Plugin */ namespace ContentControl\Plugin; use function ContentControl\plugin; defined( 'ABSPATH' ) || exit; /** * Class Install * * @since 1.0.0 */ class Install { /** * Activation wrapper. * * @param bool $network_wide Weather to activate network wide. * * @return void */ public static function activate_plugin( $network_wide ) { self::do_multisite( $network_wide, [ __CLASS__, 'activate_site' ] ); } /** * Deactivation wrapper. * * @param bool $network_wide Weather to deactivate network wide. * * @return void */ public static function deactivate_plugin( $network_wide ) { self::do_multisite( $network_wide, [ __CLASS__, 'deactivate_site' ] ); } /** * Uninstall the plugin. * * @return void */ public static function uninstall_plugin() { self::do_multisite( true, [ __CLASS__, 'uninstall_site' ] ); } /** * Handle single & multisite processes. * * @param bool $network_wide Weather to do it network wide. * @param callable $method Callable method for each site. * @param array<string,mixed> $args Array of extra args. * * @return void */ private static function do_multisite( $network_wide, $method, $args = [] ) { global $wpdb; if ( is_multisite() && $network_wide ) { $activated = get_site_option( 'content_control_activated', [] ); /* phpcs:ignore WordPress.DB.DirectDatabaseQuery.NoCaching, WordPress.DB.DirectDatabaseQuery.DirectQuery */ $blog_ids = $wpdb->get_col( "SELECT blog_id FROM {$wpdb->blogs}" ); // Try to reduce the chances of a timeout with a large number of sites. if ( \count( $blog_ids ) > 2 ) { ignore_user_abort( true ); if ( ! \ContentControl\is_func_disabled( 'set_time_limit' ) ) { /* phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged */ @set_time_limit( 0 ); } } foreach ( $blog_ids as $blog_id ) { switch_to_blog( $blog_id ); call_user_func_array( $method, [ $args ] ); $activated[] = $blog_id; restore_current_blog(); } update_site_option( 'content_control_activated', $activated ); } else { call_user_func_array( $method, [ $args ] ); } } /** * Activate on single site. * * @return void */ public static function activate_site() { // Add a temporary option that will fire a hookable action on next load. \set_transient( '_content_control_installed', true, 3600 ); $version = plugin()->get( 'version' ); // Add version info. \add_option( 'content_control_version', [ 'version' => $version, 'upgraded_from' => null, 'initial_version' => $version, 'installed_on' => gmdate( 'Y-m-d H:i:s' ), ] ); // Add data versions if missing. \add_option( 'content_control_data_versioning', \ContentControl\current_data_versions() ); } /** * Deactivate on single site. * * @return void */ public static function deactivate_site() { } /** * Uninstall single site. * * @return void */ public static function uninstall_site() { } }
SILENT KILLER Tool