Non-Ssl

  • Yoast SEO: Canonical URLs on a Site with Optional SSL

    … going to list the https path, if you’re not – it’s going to list the http path. Ugh. Within our theme’s functions.php file, and using Yoast’s canonical filter wpseo_canonical, we added the following function to force all canonical links to the secure URL: function mtb_canonical_ssl($url) { $url = preg_replace("/^http:/i", "https:", $url); return…

    Douglas Karr/ Marketing Technology Blogin SEO- 17 readers -