DarkFormula
New Member
I have a gallery that I am trying to style with CSS. Specifically, I'm trying to write CSS that looks for a specific numbered div, and then applies a new height in pixels that will override the default height. This is because I have some images that are portrait and need longer heights, versus other square images.Here's a working example of the gallery:http://kylework.com/Here's an example of the CSS I am using:\[code\]html body div#page_div div#page_content.full_width div.container_div div#mainworkpanelsheet div.mainworkpanel div:nth-child(2){height: 200px!important;}\[/code\]From that code above, I want the only the second div/image to be styled - instead every gallery div gets styled. I've also tried "div.mainworkpanel:nth-child(2)" (which I imagine is more accurate?) but that also does nothing. I've also tried selecting each div by its "background-image" property, via div[style="imageURL.jpg"] but I can't seem to get that to work either.I don't have any control over the CSS class of the divs within the gallery - they are all the same ("mainworkpanelthumb"). This gallery is being generated by jquery via an XML file. Is it not possible for CSS to override image properties after the thumbs are generated?Thanks!