Skip to content

Instantly share code, notes, and snippets.

@nholman7
Created February 26, 2018 23:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nholman7/2664d97eba913933f1610804e876f8a7 to your computer and use it in GitHub Desktop.
Save nholman7/2664d97eba913933f1610804e876f8a7 to your computer and use it in GitHub Desktop.
Add HTTPS canonical
<link rel="canonical" href="https://<?php echo $_SERVER['HTTP_HOST']; ?><?php echo parse_url( $_SERVER['REQUEST_URI'], PHP_URL_PATH ); ?>" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment