WordPress Retina (HiDPI) Display Support

Getting Started with the basic Retina Support for WordPress

text-rendering

Let’s start at the beginning of our stylesheet (style.css)

Media Queries

moving toward the bottom where technically this would be just enough:

The Future

Note that min--moz-device-pixel-ratio is for older Firefox browsers and older version of Firefox is something you’ll less likely be using with your new MacBook Pro anyways ;)

Image Replacement

There are many different techniques out there, such as retina.js, however my favorite is picturefill. This might not be the best answer if you’re looking to replace already published images with HD version.

Resources


Husband, Father, WordPress Theme Review Admin, Chicago Fire fan and creator of Responsive Theme. What more do you need?

Tagged with:
Posted in How to
4 comments on “WordPress Retina (HiDPI) Display Support
  1. fantasai says:

    I’m not sure why you’re linking to an article that explains the way to unprefix ‘-webkit-device-pixel-ratio’ is to use the standardized ‘resolution’ media query, and then not using the ‘resolution’ media query in your example.

  2. fantasai says:

    Just in case of what? Did you even read it? If so, why are you using an unprefixed ‘min-device-pixel-ratio’ query, which doesn’t exist anywhere, instead of ‘resolution’, which is part of the Media Queries standard?

    • Emil Uzelac says:

      Link removed to avoid confusion (I did read the article and it was tied to this post).

      There’s a second (Future use) Media Queries included above.
      As noted in my article fallbacks are not really needed, they’re included anyways.

      P.S. I am a Firefox user and min--moz-device-pixel-ratio was edited as well. What I had before sounded like I was saying that we should not be using Firefox and what I meant was an older version of Firefox on brand new Mac.

      Thanks for the input,
      Emil

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">