Skip to content

Instantly share code, notes, and snippets.

@iambriansreed
Last active March 21, 2017 19:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save iambriansreed/2d3cd23ecf58815cf195e5446f0ae883 to your computer and use it in GitHub Desktop.
Save iambriansreed/2d3cd23ecf58815cf195e5446f0ae883 to your computer and use it in GitHub Desktop.
Add this to the beginning of your index.php file. Useful when adding SSL to Wordpress applications.
$request = 'code_in_the_url';
$response = 'code_returned';
if ( $_SERVER['REQUEST_URI'] === ( '/.well-known/acme-challenge/' . $request ) ) {
echo $request . '.' . $response;
exit;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment