On Jan 6, 2006, at 11:01 AM, Ionize wrote:

> I have a couple of questions if you folks out there don't mind  
> answering.
>
> 1: Can CSS be used to contain an RSS Feed, what i mean by this is  
> that if
> you create a <div> container and insert the RSS code in there will  
> it be
> bound by the rules placed on it by the style sheet, not so much in a
> formatting type of way but in more of a size way.
>
> 2: With the background-image for individual divs can sepearte  
> images be used
> in each and every div?
>
> 3: How do you replace url's with images?
>
> 4: Not sure about asking this question here, but in the css zen garden
> files, any text content within a div is encolsed by <span> tags. Can
> somebody explain this?
>
> Sorry if these are silly questions, but the only way I will learn  
> is by
> asking heehee.

Not at all, Dave; that's what this list is for.

As for your answers:

1) Since RSS code isn't actual HTML, it will probably just display as  
a string of plain text, which won't be very readable at all. I  
believe you could use XSLT to transform the RSS into HTML, so it will  
then behave properly, but I'm afraid I don't know too much about that.

2) You can use as many different background images you like in  
separate divs. A common arrangement is like this:

   <div id="container">
     <div id="center-column"></div>
     <div id="left-column"></div>
     <div id="right-column"></div>
   </div>

   And the CSS:

   #center-column { background: url("center-image.png"); }
   #left-column { background: url("left-image.png"); }
   #right-column { background: url("right-image.png"); }

   Repeat for as many different divs as you need.

3) I like to use the text-indent method. HTML:

    <a id="my-link" href="/some/web/site">Come on in!</a>

    CSS:

    #my-link {
      display: block;
      text-indent: -10000em;
      width: 120px; /* width of image */
      height: 90px; /* height of image */
    }

4) When Dave Shea put the Zen garden together, he wanted to put as  
many hooks for CSS in as possible to allow maximum style flexibility  
with a single HTML file. That's the reason for the extraneous markup,  
like the spans inside the divs and the extra divs at the bottom.  
These basically just give the designers an extra element to work with  
when they're writing their style sheets.  I wouldn't recommend using  
<spans> inside <divs> in all of your work, though :)

Cheers,
Matthew Levine ([EMAIL PROTECTED])
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to