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
Solved

Grouping childs of a contextual selector

Posted on 2008-10-24
4
238 Views
Last Modified: 2011-12-28
Hello,

I currently have something like:

.bigButton .buttonLeft { background-image:url(bigButton-left.gif); }
.bigButton .buttonCenter { background-image:url(bigButton-
center.gif); }
.bigButton .buttonRight { background-image:url(bigButton-right.gif); }
.bigButton ...

How can I group the .bigButton contextual selector?
something like this:

.bigButton [
  .buttonLeft { background-image:url(bigButton-left.gif); }
  .buttonCenter { background-image:url(bigButton-center.gif); }
  .buttonRight { background-image:url(bigButton-right.gif); }
  ...
]

Regards,
DAvid
0
Comment
Question by:dportabella
4 Comments
 
LVL 42

Assisted Solution

by:David S.
David S. earned 250 total points
ID: 22799243
There's no way to do that.
0
 
LVL 44

Accepted Solution

by:
scrathcyboy earned 250 total points
ID: 22800527
why not simply join all 3 gifs using photoshop into a single button image and use --

BUTTON.big { background-image:url(bigButton.gif); }

That would be the logical way to do this, I see no reason to keep a button split into 3 parts, since you want a single click on the whole, it is only making for redundancy and cross browser problems, is it not?
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 37343923
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Creating a CSS block that only applies to printing By default, all of your CSS applies to every possible view of your page - whether on screen, printed, landscape, touch-screen, or whatever.  You can, however, add CSS that only applies under certai…
As a result of several questions about how to use Bootstrap I thought it would be a good idea to write down the development aspect of creating a Bootstrapped website in as little time as possible. Part 1 of this article will only concentrate on g…
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…

861 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