Results 1 to 3 of 3
Thread: CSS, XHTML advice needed
Feb 8, 2004, 13:06 #1
- Join Date
- Nov 2001
- 2 Post(s)
- 0 Thread(s)
CSS, XHTML advice needed
(I put this in general web dev because it involved both css and xhtml - feel free to move it if so inclined)
I just finished my second CSS/XHTML design and this one was for my personal site. I'm still learning all the nuances. I have a few questions.
Including styles: I've seen people using @import, rel and @import inside a rel style sheet. What is the preferred method? What is the purpse and advtage of including a style sheet vs importing vs including a style sheet that then imports?
I've seen a few people using multiple style sheets based on browser. Anyone care to share thoughts on this?
I'm using a 14 point pixel font. I know there is a great deal of discussion when regarding font sizing. I'm going to add my own font size changing php widget. Does this seem like a reasonable solution to the font issue?
One thing I noticed (which I should have guessed) was that the markup applies the rules on a layered bases in linear fashion, first being the lowest layer and last behing the highest (top) layer. My header is made up of a few different div tags so I can easily swap out elements of it. I had to "juggle" their order to get the rectangle image *under* the other two images. Just an observation.
When I made the switch to xhtml I found that most of the things required to be compliant were already things I practiced. There is however the matter of entities. Does there a list of entities that need to be converted to html entities? I know & is one of them that needs to be replaced.
One thing that got me more than ones was everything had to have and end tag, which I was doing with standard stuff like br, but I wasn't doing it on form fields. The forms themsevles, yes, but I didn't realize each form field also had to have the / style end tag.Chrispian H. Burks
Nothing To Say
Feb 8, 2004, 13:25 #2
@importing has a benefit: Netscape 4 can't see it. Use it to hide your advanced styles that NN4 would choke on. If you want to include advanced styles that IE chokes on but Mozilla and Opera don't, use this method of @importing your stylesheet:
@import url(/styles/mystyle.css) screen, projection;
As for special entities that must be encoded, & is probably the biggest one since it's in so many URLs (querystrings). Other biggies are " (quotes) and < (less-than sign, start of tag) and > (greater-than sign, end of tag).
Feb 8, 2004, 17:23 #3
::: certified wild guess :::
- Join Date
- May 2003
- 0 Post(s)
- 0 Thread(s)