I'm working on my portfolio site and I'm a beginner to all this.
I'm using media query to change my site for phones. When I switch my phone to landscape, it get's all out of wack.
Basically I'm having trouble with aligning my logo/contact buttons properly for different layouts. Also, on my phone the footer is completely gone!
Here is my test site I've uploaded: example
My CSS
body {
background-color:#0e0c0f;
margin: 0;
padding: 0;
}
#container{
height: 865px;
font-size: 0;
}
#logo{
margin-top: 10px;
position: fixed;
width: 100%;
height: 32px;
}
.nav{
float: right;
}
#portfolio{
margin-top: 47px;
height: 800px;
white-space: nowrap;
display: inline-block;
}
#footer{
background-color:blue;
position: fixed;
width: 100%;
height: 32px;
}
@media only screen and (max-device-width: 800px) {
#logo{
margin-top: -50px;
position: fixed;
width: 100%;
height: 20%;
background-color:#0e0c0f;
}
.logoimage{
margin-top:15px;
margin-left:15px;
}
.nav{
float:right;
margin-left:15px;
}
#portfolio{
margin-top: 47px;
white-space:normal;
display:list-item;
}
.art{
width:100%;
}
#footer{
background-color:red;
height: 32px;
}
}
And my html
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, minimum-scale=1.0, maximum-scale=1.0" />
<title>TEST</title>
<link rel="stylesheet" type="text/css" href="style2.css">
<script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js?ver=1.3.2'></script>
<script type='text/javascript' src='jquery.mousewheel.js'></script>
<script>
$(function() {
$("body").mousewheel(function(event, delta) {
this.scrollLeft -= (delta * 90);
event.preventDefault();
});
});
</script>
</head>
<body>
<div id="container">
<div id="logo">
<img src="images/logo.png" class="logoimage">
<img src="images/resume.png" class="nav">
<img src="images/contact.png" class="nav">
</div>
<div id="portfolio">
<img src="tester.png" class="art">
<img src="tester.png" class="art">
<img src="tester.png" class="art">
<img src="tester.png" class="art">
<img src="tester.png" class="art">
<img src="tester.png" class="art">
<img src="tester.png" class="art">
<img src="tester.png" class="art">
</div>
<div id="footer">
Help
</div>
</div>
</body>
</html>
Any help or tips is greatly appreciated.