Solved

Can I use a * wild card in a media query?

Posted on 2015-01-01
2
185 Views
Last Modified: 2015-01-01
Well, I guess we'll see if there are any "true geeks" workin' the holidays. :)

I've developed a simple webpage. Basically it is a fixed bg image with a video player that you can scroll down to (which actually pulls it up to center over the bg image). On smaller devices (primarily smart phones), I only load the video player with a solid black bg - that is, no bg image.

I've used media queries to load appropriate bg images on different larger devices based on 3 different aspect ratios . . . the ones that seem to be the most common in "the computing world." (16:10, 16:9, and 4:3). My question is, can I use a "device-aspect-ratio: *" query to load a generic bg of some sort for all other aspect ratios?
Is that how I would express it, by just putting an * where I would normally put say 16/9 or whatever?
0
Comment
Question by:Thunderman54
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 38

Accepted Solution

by:
Tom Beck earned 500 total points
ID: 40526593
Just specify a default background image before anything else in the "cascade".

Example:

body {
    background-image: url(...)
}


Then cover all the exceptions.
0
 

Author Comment

by:Thunderman54
ID: 40526639
Sounds good. I'll try that and get back with you. I'm getting ready to post another question maybe you can help me with. Has to do with Firefox (testing on Android tablet) not interpreting my stylesheet, media query or both.
0

Featured Post

Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

An enjoyable and seamless user experience can go a long way on an eCommerce site. While a cohesive layout and engaging copy play roles in creating a positive user experience, some sites neglect aspects that seem marginal but in actuality prove very …
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question