function wbmz_add_hsts_header() {
// Set the validity of the header, 6 months is a good starting point.
$ageInSeconds = 31536000;
// Render the header.
header( 'Strict-Transport-Security: max-age=' . $ageInSeconds . '; includeSubDomains; preload' );
}
add_action( 'send_headers', 'wbmz_add_hsts_header' );
#functions #HSTS #HTTPS #preload #SSL