background preloader

How To Use CSS3 Media Queries To Create a Mobile Version of Your Website

How To Use CSS3 Media Queries To Create a Mobile Version of Your Website
Advertisement CSS3 continues to both excite and frustrate web designers and developers. We are excited about the possibilities that CSS3 brings, and the problems it will solve, but also frustrated by the lack of support in Internet Explorer 8. This article will demonstrate a technique that uses part of CSS3 that is also unsupported by Internet Explorer 8. However, it doesn’t matter as one of the most useful places for this module is somewhere that does have a lot of support — small devices such as the iPhone, and Android devices. In this article I’ll explain how, with a few CSS rules, you can create an iPhone version of your site using CSS3, that will work now. Media Queries If you have ever created a print stylesheet for a website then you will be familiar with the idea of creating a specific stylesheet to come into play under certain conditions – in the case of a print stylesheet when the page is printed. The Media Queries in CSS3 take this idea and extend it. Testing media queries

Perfect Full Page Background Image Learn Development at Frontend Masters This post was originally published on August 21, 2009 and is now updated as it has been entirely revised. Both original methods are removed and now replaced by four new methods. The goal here is a background image on a website that covers the entire browser window at all times. Let’s put some specifics on it: Fills entire page with image, no white spaceScales image as neededRetains image proportions (aspect ratio)Image is centered on pageDoes not cause scrollbarsAs cross-browser compatible as possibleIsn’t some fancy shenanigans like Flash Image above credited to this site. Awesome, Easy, Progressive CSS3 Way We can do this purely through CSS thanks to the background-size property now in CSS3. Works in: Safari 3+Chrome Whatever+IE 9+Opera 10+ (Opera 9.5 supported background-size but not the keywords)Firefox 3.6+ (Firefox 4 supports non-vendor prefixed version) View Demo CSS-Only Technique #1 Big thanks, as usual, to Doug Neiner for this alternate version.

jQuery Mobile jQuery Mobile is an attempt to create a javascript framework that would work on all major mobile browsers. In this post I will try to lay down all the facts that I could find about jQuery Mobile, so that you are up to date. jQuery team has mentioned that they were planning and started to work on jQuery for Mobile devices when they announced jQuery 1.4. Here are some facts that I found: jQuery Mobile will be in core, NOT as a separate distribution like jquery.mobile.js jQuery UI team will improve current jQuery UI and develop new mobile components (initial designs). enquire.js - Awesome Media Queries in JavaScript The Lowdown What is it? enquire.js is a lightweight, pure JavaScript library for responding to CSS media queries. JavaScript callbacks for media queries matching and unmatching. Clean & intuitive API Absolutely tiny - around 0.8kb minified & gzipped! Why should I use it? In responsive design, CSS media queries can only take you so far. enquire.js allows you to harness media queries in JavaScript, giving you the tools to create advanced responsive sites. Dependencies? None! The most you will need to do is provide a matchMedia polyfill if you wish to support old/incapable browsers. Downloads & All That Jazz Latest Build Grab the latest code, ready to go, from one of the locations below: Development — unminified Production — minified If you wish to browse/fork the source, you can do so on GitHub. Install via Bower To install via bower, enter the following at the command line: bower install enquire Install via npm To install via npm, enter the following at the command line: npm install enquire.js Match

Le point sur le référencement de site mobile sur Google En 2008, Google a publié son premier Guide d’optimisation pour les moteurs de recherche, un résumé des bonnes pratiques à adopter en matière de référencement. Accessible et généraliste, ce document était avant tout destiné aux webmasters débutants mais avait également pu servir à confirmer des théories SEO. Le nouveau visage du GoogleBot Deux ans plus tard, ce Mardi 28 Septembre, Google publie la première mise à jour de ce « SEO Starter Guide » (en Anglais). Comment référencer deux versions d’un même contenu sans être pénalisé ? Je vous propose un résumé documenté et commenté de ces nouvelles recommandations ainsi qu’une analyse des solutions à adopter pour référencer un site en version mobile cohabitant avec une version classique. N’hésitez pas à laisser un commentaire pour ajouter votre vision des choses. S’assurer de la présence d’un site mobile dans l’index Goolge Vérifier que son site mobile est bien indexé Faire passer votre ordinateur pour un iPhone avec User Agent Switcher <? <? NON.

css - Move left-most column in a responsive design Tip for jQuery &amp; handheld device developers This week’s usual “Friday short post” about using jQuery in handheld devices. If you are a developer who is using jQuery in applications that were developed for use in environments with small processing power such as handheld devices, mobile phones, PDA’s, etc. you will find this post useful. Anyway, back to the topic. For whatever reasons you chose to use jQuery in your application (I would suggest using plain javascript for better performance) jQuery effects such as animation, hide and show, etc. most likely were probably one of the reasons. // Dissable all effectsjQuery.fx.off = true; // Shorthand$.fx.off = true; Now all your effects such as fadeIn(), fadeOut(), slideDown(), slideUp(), etc. will not be animated. NOTE: By setting the jQuery.fx.off back to false you enable all animations and effects.

Responsive Design with CSS3 Media Queries Screen resolution nowsaday ranges from 320px (iPhone) to 2560px (large monitor) or even higher. Users no longer just browse the web with desktop computers. Users now use mobile phones, small notebooks, tablet devices such as iPad or Playbook to access the web. So the traditional fixed width design doesn't work any more. View Demo Responsive Design Download Demo ZIP See It in Action First Before you start, check the final demo to see how it looks like. More Examples If you want to see more examples, check out the following WordPress themes that I designed with media queries: Tisa, Elemin, Suco, iTheme2, Funki, Minblr, and Wumblr. Overview The page's container has a width of 980px which is optimized for any resolution wider than 1024px. HTML Code I'm not going to go through the details of the HTML code. HTML5.js Note that I use HTML5 markup in my demo. Reset HTML5 Elements to Block The following CSS will reset the HTML5 elements (article, aside, figure, header, footer, etc.) to block element.

Analytics In The Palm Of Your Hand This weeks’ featured app on the Analytics App Gallery is the BAM Analytics Pro app for the iPhone. If you have ever needed to reference your site metrics in a meeting or situation where it wasn’t appropriate to fire up the laptop and open up your account, then you may find a Google Analytics smart phone app valuable. This app, developed by Blast Advanced Media (one of our Certified Partners), uses the Google Analytics API to quickly and securely access all of your reports, apply your Advanced Segments, and even create Custom Reports right within the app. You can view common preset date ranges, set a custom date range, or compare to a previous date range for additional context. All the functionality you could need within a clean, user-friendly interface. Here's a sample of custom reports functionality: BAM Analytics Pro can be purchased here on the iTunes app store for $1.99. Great work BAM!

Ultimate Responsive Web Design ToolKit When it comes to web designing industry, technology is evolving a lot with the passage of time and things are still growing with every passing day. Because of this constant evolvement, nothing can be considered as a sure shot idea to have a nice, responsive web design. This article will help designers in building a strong toolkit to make a responsive website. Getting Started In order to have a strong responsive website, there is a lot that designers have to do. Important Elements in making a Website Responsive As mentioned earlier, this field is very vast hence, important elements can be many. Advertisement A supple and fluid frameworkReactive imagesMedium being used If a responsive website is under discussion, it can be a vast one. Beginner Tools Before you even begin with website building, it is essential for you to prepare a plan related as to how the essential features on the page will acclimatize in order to fit various browser sizes of multiple devices. Sketch Sheets Foldy960 Simple Grid

Related: