[Pmwiki-users] tip from CSS list

Andres Yver yver
Wed Feb 4 08:19:11 CST 2004


Hello Wikians,
there was some discussion recently about semantics and markup.
The following snippet from the css-discuss list helped me to 
'visualize' part of the issue.
Hope it's not too obvious,,,
Andres

> I am still learning. What is a >H#> Tag? I am familiar with
> <H1>text</H1> tags. Is this the tag you are talking about?

The tags <h1> thru <h6> are what Zoe is referring to.
The reason to use them is that they and other "semantic"
tags like <p> and <ul> don't just make a browser control
an element in a certain way, but also provide a description
of what is inside them. That can come in real handy for
search engines, screen readers, and who knows what else.

By using a generic <div> and applying style to it you can
make the element visually simulate a heading or paragraph,
but those non-visual users still think it's just a <div>.

Better to use <hx> and <p>, etc., then apply styling to those
tags from the css. You can still have the look you want but
your content is then properly described. If everyone did that,
a search engine could be made to search only within certain
elements on pages, and I bet many other things would become
possible as well.
Big John




More information about the pmwiki-users mailing list