Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Yes it does for for Android and iOS. I added some sources below for those that want to understand this a bit better.</p> <p><strong>NOTE</strong>: Don't just rely on this little HTML tag! Depending on what you're making you may have to use some CSS, or Javascript/JQuery.</p> <p>You have conflicting code.<br> I'm sure you know that everything you embed goes into your body. Which is why I'm unsure as to why you set margin to -10px which means everything you embed is going to follow suit. In addition the default color of the body is set to white which again I'm wondering as to why you added that in addition with two padding properties.<br> You stated you want the webpage to fit any device. By looking at your code at face value it looks as if you grabbed bits and pieces and put it together without any knowledge as to it itself. <a href="http://www.w3schools.com/" rel="nofollow">The World Wide Web Consortium (W3C) Schools</a> page is a great place to learn the code as they're the ones who work on the world wide web.</p> <p>Here's some CSS to start out with for what you want to do by making your page responsive.</p> <pre><code>body { margin:0; padding:0; width: 100%; height: 100%; font: normal .80em arial, sans-serif; } </code></pre> <p>Now I could be wrong on what I stated before when looking at your code at face value. However if you want a responsive layout while doing Javascript functions. I find using <a href="http://jquery.com/" rel="nofollow">JQuery</a>, and <a href="http://jquerymobile.com/" rel="nofollow">JQuery Mobile</a> to be very handy. It saves massive amount of time coding, and it's built to be responsive so you don't need to write and make sure this div has x padding to match for IE. There's tons of API's available that make using JQuery, and JQuery Mobile easy to use. Everything takes learning so check into this if you haven't.</p> <p>Here's a good starting code using JQuery and JQuery Mobile.</p> <pre><code>&lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;title&gt;Site Name&lt;/title&gt; &lt;meta http-equiv='Content-Type' charset='utf-8' content='text/html;charset=ISO-8859-1'&gt; &lt;meta content='yes' name='apple-mobile-web-app-capable'&gt; &lt;meta content='default' name='apple-mobile-web-app-status-bar-style'&gt; &lt;meta content='width=device-width, height=device-height, minimum-scale=1.0, maximum-scale=1.0' name='viewport'&gt; &lt;link rel='stylesheet' href='http://code.jquery.com/mobile/1.3.1/jquery.mobile-1.3.1.min.css'&gt; &lt;script src='http://code.jquery.com/jquery-1.9.1.min.js' type='text/javascript'&gt;&lt;/script&gt; &lt;script src='http://code.jquery.com/mobile/1.3.1/jquery.mobile-1.3.1.min.js' type='text/javascript'&gt;&lt;/script&gt; &lt;style type='text/css'&gt; /* CSS Here */ &lt;/style&gt; &lt;script type='text/javascript'&gt; $(function() { // JQuery here. If you need help refer to jquery.com }); &lt;/script&gt; &lt;/head&gt; &lt;body&gt; &lt;div data-role='page'&gt; &lt;div class='header' data-role='header'&gt; &lt;h1&gt;Site Name&lt;/h1&gt; &lt;/div&gt; &lt;div class='content' data-role='content'&gt; &lt;/div&gt; &lt;/div&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p><strong>Sources</strong>:<br> <a href="http://www.w3schools.com/" rel="nofollow">http://www.w3schools.com/</a><br> <a href="http://jquery.com/" rel="nofollow">http://jquery.com/</a><br> <a href="http://jquerymobile.com/" rel="nofollow">http://jquerymobile.com/</a><br> <a href="https://developer.mozilla.org/en-US/docs/Mozilla/Mobile/Viewport_meta_tag?redirectlocale=en-US&amp;redirectslug=Mobile/Viewport_meta_tag" rel="nofollow">Using the viewport meta tag to control layout on mobile browsers</a><br> <a href="http://blog.javierusobiaga.com/stop-using-the-viewport-tag-until-you-know-ho" rel="nofollow">Stop using the viewport meta tag (until you know how to use it)</a></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload