Google Added New Ad Unit for Responsive Site – Why it is cool?

Few days ago Google launches new Google ad unit, now what? Well it’s not just an ordinary ad you’d already applied into your site like Rectangle, Square, Skyscraper and more, the new ad offers cool new feature were you can customize the ad size, yes you read it right, you can now customize the ad size depending on your need, they’re using new CSS3 selector which is @media query to customize your ad size, like 280px ad size for 320px screen size or 760px for tab orientation or something like that, this is really great and handy new feature but then again it still in beta so expect new feature and customization they can add and bring in the table 😉

Let’s take a look on the sample ad below.

Sample Ad

As you can see above they included internal style and added couple of @media styles.


Here comes the coolest things the customization, so what if I’d like to target small screen size display like iPhone?

It’s just like adding @media condition in responsive design, what you need is update @media min-width and of course the declaration property value, below is the sample code.

Want to create responsive site and the basic CSS responsive framework click here.

Hope that helps, happy customizing new ad 😉

by Ryan Sutana