WooCommerce Code Reference

Search results

WC_HTTPS

WC_HTTPS class.

Table of Contents

init() Hook in our HTTPS functions if we're on the frontend. This will ensure any links output to a page (when viewing via HTTPS) are also served over HTTPS. mixed
force_https_url() Force https for urls. string
force_https_page_link() Force a post link to be SSL if needed. string
force_https_template_redirect() Template redirect - if we end up on a page ensure it has the correct http/https url. mixed
unforce_https_template_redirect() Template redirect - if we end up on a page ensure it has the correct http/https url. mixed
http_api_curl() Force posts to PayPal to use TLS v1.2. See: https://core.trac.wordpress.org/ticket/36320 https://core.trac.wordpress.org/ticket/34924#comment:13 https://www.paypal-knowledge.com/infocenter/index?page=content&widgetview=true&id=FAQ1914&viewlocale=en_US mixed

Methods

init()

Hook in our HTTPS functions if we're on the frontend. This will ensure any links output to a page (when viewing via HTTPS) are also served over HTTPS.

public static init( ) : mixed
Return values
mixed

force_https_url()

Force https for urls.

public static force_https_url( $content : mixed ) : string
Parameters
$content : mixed
Return values
string

force_https_page_link()

Force a post link to be SSL if needed.

public static force_https_page_link( $link : string , $page_id : int ) : string
Parameters
$link : string
$page_id : int
Return values
string

force_https_template_redirect()

Template redirect - if we end up on a page ensure it has the correct http/https url.

public static force_https_template_redirect( ) : mixed
Return values
mixed

unforce_https_template_redirect()

Template redirect - if we end up on a page ensure it has the correct http/https url.

public static unforce_https_template_redirect( ) : mixed
Return values
mixed

http_api_curl()

Force posts to PayPal to use TLS v1.2. See: https://core.trac.wordpress.org/ticket/36320 https://core.trac.wordpress.org/ticket/34924#comment:13 https://www.paypal-knowledge.com/infocenter/index?page=content&widgetview=true&id=FAQ1914&viewlocale=en_US

public static http_api_curl( $handle : string , $r : mixed , $url : string ) : mixed
Parameters
$handle : string
$r : mixed
$url : string
Return values
mixed
Back to the top