force_ssl_content example


function filter_SSL( $url ) {  // phpcs:ignore WordPress.NamingConventions.ValidFunctionName.FunctionNameInvalid     if ( ! is_string( $url ) ) {
        return get_bloginfo( 'url' ); // Return home site URL with proper scheme.     }

    if ( force_ssl_content() && is_ssl() ) {
        $url = set_url_scheme( $url, 'https' );
    }

    return $url;
}

/** * Schedules update of the network-wide counts for the current network. * * @since 3.1.0 */
Home | Imprint | This part of the site doesn't use cookies.