Skip to content

Instantly share code, notes, and snippets.

@Error-331
Created June 29, 2012 17:40
Show Gist options
  • Save Error-331/3019534 to your computer and use it in GitHub Desktop.
Save Error-331/3019534 to your computer and use it in GitHub Desktop.
Mobile development notes
<meta name="viewport" content="width=device-width, initial-scale=1" /> - just what we need
480 px - most popular value of mobile screen width while in landscape mode;
<meta name="viewport" content="width=device-width, initial-scale=1" />
- tells the browser about screen scale value (it also enables the zoom);
1em = 100% ≈ 12pt ≈ 16px (but this is not always true);
<iframe src="http://www.youtube.com/embed/O-jOEAufDQ4" style="max-width:100%"></iframe> - a better way for inserting flash into the page;
Flexible Box Model - the future of responsive design;
<img src="http://src.sencha.io/http://[DOMAIN]/[PATH]/brews_images/bensons_bubbler.jpg" alt="Benson's Bubbler"> - example of how Sencha compresses the images;
you can use the bookmarklet to check the images size using javascript;
There is some sort of UAProfs besides user agent;
Opera Mini transfers all requests through Opera caching server;
XHTML-MP - mobile profile for "old" phones;
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.2//EN" "http://www.openmobilealliance.org/tech/DTD/xhtml-mobile12.dtd"> - doctype for XHTML-MP;
<a href="#dashboard" accesskey="1">Your Dashboard</a> - access keys in XHTML-MP;
For correct work of Opera Mini site must use XHTML-MP profile;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment