Created
September 19, 2017 14:35
-
-
Save rsiddle/2826590b0a07f9aede89bee148686c07 to your computer and use it in GitHub Desktop.
Showing how to switch on and off DNS-prefetch for Chrome and Firefox through multiple <meta> tags
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
... | |
<meta http-equiv="X-DNS-Prefetch-Control" content="on" /> | |
<link rel="dns-prefetch" href="https://fonts.googleapis.com" /> | |
<link rel="dns-prefetch" href="https://ajax.googleapis.com" /> | |
<link rel="dns-prefetch" href="https://cdnjs.cloudflare.com" /> | |
<link rel="dns-prefetch" href="https://www.google-analytics.com" /> | |
... | |
</head> | |
<body> | |
... | |
<article> | |
<p>Make sure you check out the <a href="https://dev.chromium.org/developers/design-documents/dns-prefetching">Chromium project</a>!</p> | |
</article> | |
<div class="comments-box"> | |
<meta http-equiv="X-DNS-Prefetch-Control" content="off" /> | |
<div class="comment"> | |
<span class="author">Joe Blogs</span> | |
<p>Hey, check out <a href="https://example.com">Example</a>, it’s a domain holder.</p> | |
</div> | |
<div class="comment"> | |
<span class="author">John Smith</span> | |
<p>What about <a href="https://placeholder.it">Placeholders</a>, for HTML design?</p> | |
</div> | |
<meta http-equiv="X-DNS-Prefetch-Control" content="on" /> | |
</div> | |
<footer> | |
<a href="https://merj.com">MERJ Parent Company</a> © 2017 | |
</footer> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment