IneverReadAnythingSentToMe@hotmail.com (David Filmer) wrote in
news:e4c916dd.0401161142.6cc65c45@posting.google.c om:
[color=blue]
> I'm working on a new version of the site that uses the open-source
> "Plans" calendar (
http://planscalendar.com/demo) which is rather
> highly styled (
http://planscalendar.com/demo/theme/plans.css). I want
> to also include a snippet of this calendar on my site's mainpage (same
> as I do with
http://troop606.com). I don't want my snippet to be
> dependent on changes that I make to the Plans .css file (which may not
> be compatible with (or may be overwritten by) future versions of
> Plans). I don't know how to apply the stylesheet to ONLY the calendar
> snippet (and not the rest of the mainpage).
>
> The calendar snippet HTML and the .css are from Plans. All I'm trying
> to do is extract a portion of that HTML (which I know how to do) and
> display it on my mainpage, with the .css applied (which I don't know
> how to do).[/color]
In the HTML, wrap the section you want to style in a <div> element with its
class attribute set to some name of your choosing, e.g.
<div class="styled">A bunch of stuff</div>. Then make a copy of the css
file for plans and prefix each selector with ".styled " (or whatever class
name you chose); don't leave out the trailing space. That will make all
the rules apply only to the contents of the <div> you added to the HTML.