I looked through the previous questions but none touched on my exact issue.I would consider myself to be beginner - intermediate level at html / css. I am working on a basic responsive page using html and css, which swaps out images depending on max screen width in media queries, so that as the max screen width reduces, images switch out for smaller images at certain break points.When I test this locally by dragging the html into a private browsing window and my own hosted domain it works both places as expected.However - when I upload the files to the server where it will be hosted(classic Linux cPanel set up on GoDaddy) all of the images show all the time, instead of only when called by the media query.As part of the troubleshooting I have tried this two ways - the original html has an img src for both sizes of image(which is why it 's commented out in the sample below), but even if I remove the img src calls for the -sm versions, the same problem persists, but ONLY on the cPanel host.
Is there a solution that will get this to play nice with cPanel ? Any input appreciated - thanks!!
Here is the html :
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>GoPlay Families</title>
<meta name="author" content="Janelle Schneider"/>
<meta name="description" content="GoPlayFamilies is a deck of cards that offers 52 fun activities for families."/>
<meta name="google-site-verification" content=""/>
<meta name="Copyright" content="© copyright 2015 GoPlayFamilies All Rights Reserved"/>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="shortcut icon" href="favicon.ico"/>
<link rel="stylesheet" href="css/reset.css"/>
<link rel="stylesheet" href="css/style.css"/>
</head>
<body>
<div id="wrapper">
<!--outer wrapper-->
<!-- header -->
<header>
<div id="logo">
<img src="../images/goplayfamilies.png" alt="">
<!--<img src="../images/goplayfamilies_sm.png" alt="">-->
</div>
<div id="tagline">
<img src="../images/deckofplayingcards.png" alt="">
<!--<img src="../images/deckofplayingcards_sm.png" alt="">-->
</div>
</header>
<!-- main content -->
<main>
<div id="maincontainer">
<div id="fade">
<h1>Coming Soon</h1>
<p></p>
<div class="main-img1">
<img src="../images/goplayappicon.png" alt="">
</div>
<div class="main-img2">
<img src="../images/topcardbox_sq.png" alt="">
</div>
</div>
</div>
</main>
<!-- footer -->
<footer>
<p>
<div class="copyright">© Copyright GoPlayFamilies. All Rights Reserved. </div>
</footer>
Here is one of the css media queries:
@media only screen and(max-width: 594 px) {
#logo {
background - image: url("../images/goplayfamilies_sm.png");
background - repeat: no - repeat;
height: 100 % ;
width: 100 % ;
margin - left: auto;
margin - right: auto;
margin - top: 0 % ;
}
#tagline {
background - image: url("../images/deckofplayingcards_sm.png");
background - repeat: no - repeat;
height: 100 % ;
width: 100 % ;
margin - left: auto;
margin - right: auto;
margin - top: 5e m;
}
header {
display: block;
background - position: top;
height: 150 px;
width: 100 % ;
padding: 20 px;
background: #621417;
}
main {
display: block;
width: 100%;
background-color: # 4 b514d;
bottom: 0;
top: 0;
height: 100 % ;
}
h1 {
font - size: 1.5e m;
margin: auto;
}
#maincontainer {
height: 100 % ;
display: table;
margin - left: auto;
margin - right: auto;
padding: 0 10 % 10 % 10 % ;
}
.main - img1 {
float: none;
margin: auto;
margin - top: 27 px;
}
.main - img2 {
margin: auto;
padding: 10 % ;
margin - top: 27 px;
}
}