| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
| DesignersTalk > how to "wrap" html+css+js ads code for multiple site include |
|
LinkBack | Thread Tools | Search this Thread |
|
|
#1 (permalink) |
|
Registered User
Join Date: May 2008
Posts: 1
|
how to "wrap" html+css+js ads code for multiple site include
hi! i want to display the a set of ads to multiple websites. i made a rotating image carousel made with html+css+javascript. this is called by a simple php include in all of our websites. the problem is that the included code (the carousel's html+css code) inherits some of the styles of the page on which it was embedded. i already tried 'resetting' the styles of the tags i used within the carousel: Code:
but there are still some global styles defined in the pages (on which the carousel code was embedded) that mess up the carousel code. i'm looking for ways for me not to test the carousel code on all of the websites where it will be used and override 'all' the styles that it will inherit. is there an easy way to 'wrap' the carousel code so it won't inherit any styles from its parent page. i'm already considering a flash-based solution but i'm hoping there's still a way to fix this. anyway here's my carousel code: Code:
thanks! |
|
|
|
|
|
#3 (permalink) |
|
Senior Member
Join Date: May 2007
Location: England
Posts: 154
|
To overwrite any inherit simply give your carousel <div> containers ids, then use these IDs and whatever element in the CSS, this should over ride any inherit. Code:
If this dosnt work then a quick fix solution is to embed the carousel in an Iframe EDIT: ACtully looking at your CSS, you have a mistake #adsCarouselBox ul li img a p { This is how ID is declared not class, for class you need .adsCarouselBOx etc. You kind of confusig the issue, by declaring a element UL, then giving the element the class adscarousel.. ... THis is where things could be going wrong, make changes to this first to see if that works, otherwise go in over the top with a double ID and element declaration as I previously mentioned. Wot Speeling Mishtake?
|
|
![]() |