Forum Moderators: not2easy
<style type="text/css">
.sideBar blah {
float: right;
width: 200px;
color: #565FED;
}
</style>
...can you then use that css block like so?
<div class="sideBar">
<blah>This is text</blah>
<blah>This is also text</blah>
</div>
Thing is, this seems completely wrong to me so now I'm wondering. How does .sideBar somethinghere work?
But the way you have the code set up in your example, yes, that's how you'd refer to a child of something.
<style type="text/css">
.sideBar p {
float: right;
width: 200px;
color: #565FED;
}
</style><div class="sideBar">
<p>This is text</p>
<p>This is also text</p>
</div>
CSS
#blah {
stuff...
}
But if you wanted a tag called <blah> you'd need XML... which IE doesn't understand on web pages : ) But maybe someday in the distant future...
*Edit what's up with these code tags, they're totally making my code unreadable! Where's my whitespace? *
[edited by: Stomme_poes at 10:15 am (utc) on Feb. 16, 2008]