acf_strip_protocol()ACF 5.5.4

This function will remove the proticol from a url Used to allow licenses to remain active if a site is switched to https

Хуков нет.

Возвращает

Строку.

Использование

acf_strip_protocol( $url );
$url(строка) (обязательный)
The URL to strip the protocol from.

Список изменений

С версии 5.5.4 Введена.

Код acf_strip_protocol() ACF 6.4.2

function acf_strip_protocol( $url ) {

	// strip the protocol
	return str_replace( array( 'http://', 'https://' ), '', $url );
}