Media Types in Stylesheet

Posted By : Gaurav Arora | 28-Sep-2017

Hi, as we know that while calling our stylesheet, we define media in our link where we call our stylesheet. Normally we use media="all" and sometimes we don't even use this, but there some other options that we use to particular conditions.

 

A basic usage of the above is:


 

In this blog we will cover all these media types:

So, Basically we have 10 media types : all, embossed, braille, projection, handheld, print, screen, speech, tty, tv.

Lets cover them one by one.

all : This media type is suitable for all devices.

embossed : This media type is meant to use for paged braille printers.

brailler : This media type is meant to use for braille tactile feedback devices.

projection : This media type is meant to use for projected work, we can take an example of Projector.

handheld : This media type is meant to use for handheld devices for example : small screen devices.

print : This media type is meant to use for printing purpose only, Lets take an example, like we have to define some particular styles to page only in print view. In that case we use print media.

screen : This media type is meant to use for computer screens.

speech : This media type is meant to use for speech synthesizers. In CSS2 we have a similar media type Aural which was used for the same purpose.

tty : This media type is meant to use for fixed pitch character grid. For example terminals or portable devices with limited capabilities.

tv : This media type is meant to use for low resolution devices or television kind of device.

But make sure that you define them the same, as they are case sensitive.

That's all. This was a basic description to understand the media types that we use in our Stylesheet.

About Author

Author Image
Gaurav Arora

Gaurav is an experienced UI developer with experience and capabilities to build compelling UI's for Web and Mobile Applications.

Request for Proposal

Name is required

Comment is required

Sending message..