Skip to content

Instantly share code, notes, and snippets.

@cpres
Created July 3, 2014 00:55
Show Gist options
  • Save cpres/b120167a3f7a56f433bc to your computer and use it in GitHub Desktop.
Save cpres/b120167a3f7a56f433bc to your computer and use it in GitHub Desktop.
Windows Phone 8 Helper Script - For use with Bootstrap.js and others
<script type="text/javascript">
<!--
(function() {
if ("-ms-user-select" in document.documentElement.style && navigator.userAgent.match(/IEMobile\/10\.0/)) {
var msViewportStyle = document.createElement("style");
msViewportStyle.appendChild(
document.createTextNode("@-ms-viewport{width:auto!important}")
);
document.getElementsByTagName("head")[0].appendChild(msViewportStyle);
}
})();
//-->
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment