Astra_Minify::astra_is_ssl()

Checks to see if the current site is being accessed over SSL.


Description


Return

(bool)


Source

File: classes/class-astra-minify.php

		public static function astra_is_ssl() {
			if ( is_ssl() ) {

				return true;
			} elseif ( 0 === stripos( get_option( 'siteurl' ), 'https://' ) ) {

				return true;
			} elseif ( isset( $_SERVER['HTTP_X_FORWARDED_PROTO'] ) && 'https' == $_SERVER['HTTP_X_FORWARDED_PROTO'] ) {

				return true;
			}

			return false;
		}

Changelog

Changelog
Version Description
1.0 Introduced.

User Contributed Notes

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