Using media queries in the head of the index html doc, is it possible to tell the visitors browser to use a separate style sheet independently of the original stylesheet?
Currently, what I use uses the mobile_specific stylesheet in addition to the original one which is becoming tricky to style.
<link type="text/css" media="screen" href="styles.css" rel="stylesheet">
<link href="styles_mobile.css" media="only screen and (max-device-width: 480px)" type="text/css" rel="stylesheet">
So syles_mobile.css is used in addition to styles.css. How do I tell the browser to use ONLY “styles_mobile.css” and not both the stylesheets together?
Add a media query to the regular stylesheet who is the oposite of your mobile query:
PS: I suggest you to use a standard order of attributes. And the
typeattribute is not required, as it has a default value oftext/csswith link and style elements and a default value oftext/javascripton script elements.