Code: Select all
<meta name="viewport" content="width=device-width, initial-scale=1">
El último intento es el siguiente:
Code: Select all
<!DOCTYPE html>
<html dir="<?php echo $direction; ?>" lang="<?php echo $lang; ?>">
<head>
<meta charset="utf-8">
<head>
[b]<meta name="viewport" content="width=device-width, initial-scale=1.0" />[/b]
<head>
<style>
.container {
width:996px;
margin:0px auto;
font-size:1em;
}
section,aside {
padding: 10px;
background:#ccc;
-moz-border-radius:5px;-webkit-border-radius:5px;-o-border-radius:5px;border-radius:5px;
}
section {
float: left;
width: 70%;
}
aside {
float: right;
width: 25%;
}
nav {
overflow: hidden;
}
nav ul {
list-style-type:none;
float:left;
padding:0px;
}
nav ul li {
float:left;
padding:3px 10px;
margin:2px;
background:#ccccff;
-moz-border-radius:5px;-webkit-border-radius:5px;-o-border-radius:5px;border-radius:5px;
}
footer {
margin:10px;
text-align:center;
clear:both;
}
/* para 980px o menos */
@media screen and (max-width:980px) {
.container {
width:98%;
}
section {
width:68%;
}
}
/* para 700px o menos */
@media screen and (max-width:700px) {
aside,section {
float:none;
width:96%;
}
nav, section {
font-size:1.2em;
}
aside {
margin-top:5px;
}
nav ul {
float:none;
clear:both;
}
}
/* para 480px o menos */
@media screen and (max-width:480px) {
aside {
display:none;
}
nav, section {
font-size:1.5em;
}
section {
width:94%;
}
nav ul {
float:left;
clear:none;
width:50%;
}
nav ul li {
float:none;
}
}
</style>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-55864520-1', 'auto');
ga('send', 'pageview');
.
.
.
Muchas gracias de antemano.
Un saludo