The Adblock Project Forum Index The Adblock Project
Pull up a seat ...stay a while.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CSS/usercontent question: parent selectors?

 
Post new topic   Reply to topic    The Adblock Project Forum Index -> Main
View previous topic :: View next topic  
Author Message
Drahken



Joined: 30 Oct 2004
Posts: 107

PostPosted: Mon Apr 11, 2005    Post subject: CSS/usercontent question: parent selectors? Reply with quote

How can I select a PARENT (not a child) element in CSS? For example: There's an ad surrounded by a table. The ad is blocked with a proxy, but the table remains because it was given specific dimensions. The table has no class nor ID, and blocking it based on the specified dimensions could cause problems elsewhere. Using table>embed only seems to target the embedded ad, would table<embed target the table? ...Or is there no way to target a parent element in CSS yet?
Back to top
View user's profile Send private message
AmirG



Joined: 26 Mar 2005
Posts: 119

PostPosted: Mon Apr 11, 2005    Post subject: Reply with quote

I use the URIid extension for this. With this extension, you can block elements in the userContent.css just on specific sites, great for removing placeholders for ads. The only problem with this is that with this extension, the bloking seems to take place only after the page is fully loaded, so whatever you're blocking will flash on the screen for a second.
Back to top
View user's profile Send private message
Guest






PostPosted: Sat Apr 23, 2005    Post subject: Reply with quote

If you're using Fx developers builds, or Mozilla Suite 1.8a3+, you no longer need the uriid extension. Gecko now supports CSS rules on a per-site (or even per-uri) basis out of the box. For example, put the following in your userContent.css to block div.annoyingad on example.com only:

Code:

@-moz-document domain(example.com) {
  .annoyingad {display: none ! important; }
}


More information can be found in bug 238099. As I understand, this feature will be in Fx1.1, though for now it's only available to the adventurous...
Back to top
Display posts from previous:   
Post new topic   Reply to topic    The Adblock Project Forum Index -> Main All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group