I'm trying to use some HTML and CSS to create a DIV style that will do basically what the phpBB code block does. I am hoping that I'll be able to use <div class="code"></div> and the code surrounded by those tags would be indented, preformatted, etc. I've managed to get the block indented and background colours correct, but I haven't been able how to get the preformatting look to it. The code I have so far is:
Code: Select all
div.code {
margin: 3px;
background-color: #DDDDDD;
}Code: Select all
white-space: pre;I'm going to look through the phpBB source, but tracking it down could take quite a while. If anyone would know how to do something like this, that would be greatly appreciated.
Sphenn