Okay... this is bound to result ins a whole bunch of "personal" opinions, but I shall ignore those :)
It is possible to apply borders with CSS.
What is not yet fully supported are the various special "fancy" border options for things like Curved Edges, Drop Shadows etc... so we are forced to resort to using images etc.
What I'm after is some input on what is deemed as "acceptable markup" for creating these boxes.
Right, criteria ...
- I avoid using JS/DOM as much as possible, so those are out.
- I am not a "Purist", though I would prefer to use "less code" over "more code".
- I always am for Fluid/Flexible/Dynamic designs, so fixed Height/Width is out.
- I am aiming for the "Most" potential design, thus all four edges and all four corners!
Imagine having you content in a nice little block. Boring. The Client wants funny shapped corners, 3D looking edging around the content, and fancies either a dropped shadow or glow around the whole lot. Not Nice! (Hey, They can pay for it ;) )
Now, the only method I can come up with involves either Div's to the Max and some dodgey Margin/Padding work for CSS Background-Images and Cross Browser support.... OR Almost as many Divs and several Images for the Corners with some Positioning.
Is there a better way than having 8+ Divs? Also, whilst I'm at it, is there really any practical CODE difference between using umpten Divs or Umpteen Spans?
Dude,
Nice questions, however, for the time being it seems that NO is the answer to your search. And I mean - no, it is not possible for the time being to save yourself a lot of coding if you want to make everything look rounded, in different shapes, etc...
Remember - everything apearing on your monitor is squares - how big or tiny, it depends what are you aiming for, still it remains square. So there is no easy way to make it round ;). As far as the curved borders, hmm interesting, but still not easy to achieve yet.
And at the end, maybe I don't get your question right, however, the difference between DIV and SPAN is that div is a block element, while span is an in-line element. This means you can place a span between the and
, but if you place div like that - you have a non validated code.